mirror of
https://github.com/odoo/runbot.git
synced 2025-03-15 23:45:44 +07:00
[FIX] runbot: export diff_match_patch
Fixes the export of diff_match_patch, it previously used global export which is not supported anymore (at least not the way it was doing it before).
This commit is contained in:
parent
f847ba57e1
commit
33bef243d2
@ -1,6 +1,7 @@
|
||||
/** @odoo-module **/
|
||||
import { patch } from "@web/core/utils/patch";
|
||||
import { Message } from "@mail/core/common/message";
|
||||
import { diff_match_patch } from "@runbot/libs/diff_match_patch/diff_match_patch";
|
||||
|
||||
patch(Message.prototype, {
|
||||
setup() {
|
||||
@ -76,4 +77,4 @@ patch(Message.prototype, {
|
||||
}
|
||||
return lines;
|
||||
},
|
||||
});
|
||||
});
|
||||
|
@ -2226,11 +2226,18 @@ var diff_match_patch = function() {
|
||||
// In a browser, 'this' will be 'window'.
|
||||
// Users of node.js should 'require' the uncompressed version since Google's
|
||||
// JS compiler may break the following exports for non-browser environments.
|
||||
/** @suppress {globalThis} */
|
||||
this['diff_match_patch'] = diff_match_patch;
|
||||
/** @suppress {globalThis} */
|
||||
this['DIFF_DELETE'] = DIFF_DELETE;
|
||||
/** @suppress {globalThis} */
|
||||
this['DIFF_INSERT'] = DIFF_INSERT;
|
||||
/** @suppress {globalThis} */
|
||||
this['DIFF_EQUAL'] = DIFF_EQUAL;
|
||||
// /** @suppress {globalThis} */
|
||||
// this['diff_match_patch'] = diff_match_patch;
|
||||
// /** @suppress {globalThis} */
|
||||
// this['DIFF_DELETE'] = DIFF_DELETE;
|
||||
// /** @suppress {globalThis} */
|
||||
// this['DIFF_INSERT'] = DIFF_INSERT;
|
||||
// /** @suppress {globalThis} */
|
||||
// this['DIFF_EQUAL'] = DIFF_EQUAL;
|
||||
|
||||
export {
|
||||
diff_match_patch,
|
||||
DIFF_DELETE,
|
||||
DIFF_INSERT,
|
||||
DIFF_EQUAL
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user