Index: trunk/extensions/MoodBar/ApiFeedbackDashboardResponse.php |
— | — | @@ -47,18 +47,20 @@ |
48 | 48 | $this->disableUserTalkEmailNotification(); |
49 | 49 | |
50 | 50 | $id = intval( $item->getProperty( 'id' ) ); |
51 | | - $api = new ApiMain( new FauxRequest( array( |
52 | | - 'action' => 'edit', |
53 | | - 'title' => $talkPage->getFullText(), |
54 | | - 'appendtext' => ( $talkPage->exists() ? "\n\n" : '' ) . |
55 | | - $feedback_link . "\n" . |
56 | | - '<span id="feedback-dashboard-response-' . $id . '"></span>' . "\n\n" . |
57 | | - $response . "\n\n~~~~\n\n" . |
58 | | - '<span class="markashelpful-mbresponse-' . $id . '"> </span>', |
59 | | - 'token' => $params['token'], |
60 | | - 'summary' => $summary, |
61 | | - 'notminor' => true, |
62 | | - ), true, array( 'wsEditToken' => $wgRequest->getSessionData( 'wsEditToken' ) ) ), true ); |
| 51 | + $api = new ApiMain( new DerivativeRequest( |
| 52 | + $wgRequest, |
| 53 | + array( |
| 54 | + 'action' => 'edit', |
| 55 | + 'title' => $talkPage->getFullText(), |
| 56 | + 'appendtext' => ( $talkPage->exists() ? "\n\n" : '' ) . |
| 57 | + $feedback_link . "\n" . |
| 58 | + '<span id="feedback-dashboard-response-' . $id . '"></span>' . "\n\n" . |
| 59 | + $response . "\n\n~~~~\n\n" . |
| 60 | + '<span class="markashelpful-mbresponse-' . $id . '"> </span>', |
| 61 | + 'token' => $params['token'], |
| 62 | + 'summary' => $summary, |
| 63 | + 'notminor' => true, |
| 64 | + ), true, array( 'wsEditToken' => $wgRequest->getSessionData( 'wsEditToken' ) ) ), true ); |
63 | 65 | |
64 | 66 | $api->execute(); |
65 | 67 | |