mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-10 08:33:30 +01:00
Throw an error if you try to initiate a new SnowflakeUtil class instance (#1413)
This commit is contained in:
@@ -8,6 +8,10 @@ let INCREMENT = 0;
|
||||
* A container for useful snowflake-related methods
|
||||
*/
|
||||
class SnowflakeUtil {
|
||||
constructor() {
|
||||
throw new Error(`The ${this.constructor.name} class may not be instantiated.`);
|
||||
}
|
||||
|
||||
/**
|
||||
* A Twitter snowflake, except the epoch is 2015-01-01T00:00:00.000Z
|
||||
* ```
|
||||
|
||||
Reference in New Issue
Block a user