jenkins-bot has submitted this change and it was merged.

Change subject: Revert "Add Flow MessagePoster"
......................................................................


Revert "Add Flow MessagePoster"

Back out until the core change is ready to be merged.

This reverts commit 49ffd141e0a80af3f1f1421d163a1ae8d47f88b8.

Change-Id: Ifff3510999249e13356bc6cd154ec0881e834c00
---
M Resources.php
D modules/messagePoster/ext.flow.messagePoster.js
2 files changed, 0 insertions(+), 69 deletions(-)

Approvals:
  Mattflaschen: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/Resources.php b/Resources.php
index 67637fb..9511d0a 100644
--- a/Resources.php
+++ b/Resources.php
@@ -504,18 +504,6 @@
                        'editor/ext.flow.parsoid.js',
                ),
        ) + $mobile,
-       // This integrates with core mediawiki.messagePoster, and the module 
name
-       // must be exactly this.
-       'mediawiki.messagePoster.flow-board' => $flowResourceTemplate + array(
-               'scripts' => array(
-                       'messagePoster/ext.flow.messagePoster.js',
-               ),
-               'dependencies' => array(
-                       'oojs',
-                       'mediawiki.api',
-                       'mediawiki.messagePoster',
-               ),
-       ) + $mobile,
        'ext.flow.jquery.conditionalScroll' => $flowResourceTemplate + array(
                'scripts' => array(
                        'engine/misc/jquery.conditionalScroll.js',
diff --git a/modules/messagePoster/ext.flow.messagePoster.js 
b/modules/messagePoster/ext.flow.messagePoster.js
deleted file mode 100644
index 1937f1c..0000000
--- a/modules/messagePoster/ext.flow.messagePoster.js
+++ /dev/null
@@ -1,57 +0,0 @@
-( function ( $, mw, OO ) {
-       mw.flow = mw.flow || {};
-
-       /**
-        * This is an implementation of MessagePoster for Flow boards
-        *
-        * The title can be a non-existent board, but it will only work if Flow 
is allowed in that
-        * namespace or the user has flow-create-board
-        *
-        * @class
-        * @constructor
-        *
-        * @extends mw.messagePoster.MessagePoster
-        *
-        * @param {mw.Title} title Title of Flow board
-        */
-       mw.flow.MessagePoster = function MwFlowMessagePoster( title ) {
-               // I considered using FlowApi, but most of that functionality 
is about mapping <form>
-               // or <a> tags to AJAX, which is not applicable.  This allows 
us to keep
-               // mediawiki.messagePoster.flow-board light-weight.
-
-               this.api = new mw.Api();
-               this.title = title;
-       };
-
-       OO.inheritClass(
-               mw.flow.MessagePoster,
-               mw.messagePoster.MessagePoster
-       );
-
-       /**
-        * @inheritdoc
-        */
-       mw.flow.MessagePoster.prototype.post = function ( subject, body ) {
-               mw.flow.MessagePoster.parent.prototype.post.call( this, 
subject, body );
-
-               return this.api.postWithToken( 'edit', {
-                       action: 'flow',
-                       submodule: 'new-topic',
-                       page: this.title.getPrefixedDb(),
-                       nttopic: subject,
-                       ntcontent: body,
-                       ntformat: 'wikitext',
-                       ntmetadataonly: 1
-               }, {
-                       // IE 8 seems to have cached some POST requests without 
this
-                       cache: false
-               } ).then(
-                       null, // Preserve parameters from postWithToken promise
-                       function ( code, details ) {
-                               return $.Deferred().reject( 'api-fail', code, 
details );
-                       }
-               ).promise();
-       };
-
-       mw.messagePoster.factory.register( 'flow-board', mw.flow.MessagePoster 
);
-} ( jQuery, mediaWiki, OO ) );

-- 
To view, visit https://gerrit.wikimedia.org/r/202292
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ifff3510999249e13356bc6cd154ec0881e834c00
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Flow
Gerrit-Branch: wmf/1.25wmf24
Gerrit-Owner: Mattflaschen <[email protected]>
Gerrit-Reviewer: Mattflaschen <[email protected]>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to