Remove Deprecated Shared Secret Package#6540
Conversation
| const SharedSecret = []; | ||
|
|
||
| if (Meteor.isServer) { | ||
| const EncryptMessage = (() => { |
There was a problem hiding this comment.
If you want to "make a class", I think that you removed/forgot one () here
const Class = (()=>{return function(){}})()nowadays you can just use class EncryptMessage {...}
but I think that in all situations could be simple functions.
like:
function HandleSlashCommand(command, params, item) {...}| const SharedSecret = []; | ||
|
|
||
| if (Meteor.isServer) { | ||
| const EncryptMessage = ((message) => { |
There was a problem hiding this comment.
Lets use named function for theses cases (high level functions / were we used classes before) to help the stack trace.
function EncryptMessage(message) {
| if (message.urls) { | ||
| const messageUrls = message.urls; | ||
| messageUrls.forEach((i) => { | ||
| const urls = messageUrls[i]; |
There was a problem hiding this comment.
The i is the urls already. Just rename the i to urls and remove the const urls = messageUrls[i];
| return message; | ||
| })(); | ||
|
|
||
| const HandleSlashCommand = ((command, params, item) => { |
| } | ||
|
|
||
| if (Meteor.isClient) { | ||
| const DecryptMessage = ((message) => { |
| if (message.urls) { | ||
| const messageUrls = message.urls; | ||
| messageUrls.forEach((i) => { | ||
| const urls = messageUrls[i]; |
| return message; | ||
| })(); | ||
|
|
||
| const HandleSlashCommand = ((command, params, item) => { |
|
This may be a stupid question, but I don't see this package used anywhere. It's not within |
|
@Kiran-Rao You are right. I'll double check that |
|
@Kiran-Rao we decided to remove the package, it was there as an optional package. @MartinSchoeler Can you delete the files and add a note to HISTORY.md about this removal? Like |
and update history
@RocketChat/core