remove compatability bs
This commit is contained in:
parent
9d937fe0b5
commit
ae26be7772
|
@ -223,10 +223,6 @@ function evaluate(str, exportsR) {
|
||||||
// expose EPAPI as $api, which is what most plugins expect it to be known as
|
// expose EPAPI as $api, which is what most plugins expect it to be known as
|
||||||
window.$api = exports;
|
window.$api = exports;
|
||||||
|
|
||||||
// extension methods used in some older plugins, maintained for compatibility
|
|
||||||
String.prototype.replaceAll = function (search, replacement) { return this.split(search).join(replacement) };
|
|
||||||
Array.prototype.contains = function (s) { return this.indexOf(s) != -1 };
|
|
||||||
|
|
||||||
// derive the date of creation from a discord snowflake id
|
// derive the date of creation from a discord snowflake id
|
||||||
Date.fromSnowflake = (id) => new Date((id / 4194304) + 1420070400000);
|
Date.fromSnowflake = (id) => new Date((id / 4194304) + 1420070400000);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue