Skip to content

Commit

Permalink
Merge pull request #11926 from vector-im/travis/fix-rageshake
Browse files Browse the repository at this point in the history
Fix rageshake post-sourcemaps
  • Loading branch information
turt2live authored Jan 18, 2020
2 parents e3b4f18 + cdd25ea commit 342d717
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions src/vector/rageshakesetup.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
/*
Copyright 2018 New Vector Ltd
Copyright 2020 The Matrix.org Foundation C.I.C.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -27,6 +28,7 @@ limitations under the License.

import * as rageshake from "matrix-react-sdk/src/rageshake/rageshake";
import SdkConfig from "matrix-react-sdk/src/SdkConfig";
import sendBugReport from "matrix-react-sdk/src/rageshake/submit-rageshake";

function initRageshake() {
rageshake.init().then(() => {
Expand Down Expand Up @@ -54,15 +56,13 @@ global.mxSendRageshake = function(text, withLogs) {
console.error("Cannot send a rageshake without a message - please tell us what went wrong");
return;
}
require(['matrix-react-sdk/src/rageshake/submit-rageshake'], (s) => {
s(SdkConfig.get().bug_report_endpoint_url, {
userText: text,
sendLogs: withLogs,
progressCallback: console.log.bind(console),
}).then(() => {
console.log("Bug report sent!");
}, (err) => {
console.error(err);
});
sendBugReport(SdkConfig.get().bug_report_endpoint_url, {
userText: text,
sendLogs: withLogs,
progressCallback: console.log.bind(console),
}).then(() => {
console.log("Bug report sent!");
}, (err) => {
console.error(err);
});
};

0 comments on commit 342d717

Please sign in to comment.