Physikerwelt has submitted this change and it was merged.

Change subject: Fix: Remove MathML out if used as input
......................................................................


Fix: Remove MathML out if used as input

* For some reason it causes problems if the input
  MathML is used in the output and contains special chars.
* Since the output MathML is not really needed in the output
  the mml field is set to '' and src field
  is set to the static value 'mathml' in that case.

Bug: 62921
Change-Id: I014da024e20cd080bec6c4f8c9a6da73cc38675e
---
M main.js
1 file changed, 6 insertions(+), 0 deletions(-)

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



diff --git a/main.js b/main.js
index 860af75..8813a28 100644
--- a/main.js
+++ b/main.js
@@ -184,6 +184,12 @@
   if(query.format == 'json'){
       if ( validRequest ) {
           resp.statusCode = 200;
+          //Temporary fix for BUG 62921
+          if (query.type == 'mml'){
+              mml = '';
+              src = 'mathml';
+          }
+          //End of fix
           out = JSON.stringify({input:src,
               svg:svg_or_error,
               mml:mml,

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I014da024e20cd080bec6c4f8c9a6da73cc38675e
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/services/mathoid
Gerrit-Branch: master
Gerrit-Owner: Physikerwelt <w...@physikerwelt.de>
Gerrit-Reviewer: Physikerwelt <w...@physikerwelt.de>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to