diff --git a/.eslintrc.js b/.eslintrc.js
new file mode 100644
index 0000000..67acfd6
--- /dev/null
+++ b/.eslintrc.js
@@ -0,0 +1,18 @@
+module.exports = {
+ env: {
+ es6: true,
+ node: true
+ },
+ extends: [
+ 'standard'
+ ],
+ globals: {
+ Atomics: 'readonly',
+ SharedArrayBuffer: 'readonly'
+ },
+ parserOptions: {
+ ecmaVersion: 2018
+ },
+ rules: {
+ }
+}
diff --git a/.gitignore b/.gitignore
index 656811d..a48438c 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,4 +1,3 @@
-node_modules
-data
-config.js
-package-lock.json
\ No newline at end of file
+.vscode
+*config.js
+node_modules
\ No newline at end of file
diff --git a/LICENSE b/LICENSE
new file mode 100644
index 0000000..dbbe355
--- /dev/null
+++ b/LICENSE
@@ -0,0 +1,661 @@
+ GNU AFFERO GENERAL PUBLIC LICENSE
+ Version 3, 19 November 2007
+
+ Copyright (C) 2007 Free Software Foundation, Inc.
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+ Preamble
+
+ The GNU Affero General Public License is a free, copyleft license for
+software and other kinds of works, specifically designed to ensure
+cooperation with the community in the case of network server software.
+
+ The licenses for most software and other practical works are designed
+to take away your freedom to share and change the works. By contrast,
+our General Public Licenses are intended to guarantee your freedom to
+share and change all versions of a program--to make sure it remains free
+software for all its users.
+
+ When we speak of free software, we are referring to freedom, not
+price. Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+them if you wish), that you receive source code or can get it if you
+want it, that you can change the software or use pieces of it in new
+free programs, and that you know you can do these things.
+
+ Developers that use our General Public Licenses protect your rights
+with two steps: (1) assert copyright on the software, and (2) offer
+you this License which gives you legal permission to copy, distribute
+and/or modify the software.
+
+ A secondary benefit of defending all users' freedom is that
+improvements made in alternate versions of the program, if they
+receive widespread use, become available for other developers to
+incorporate. Many developers of free software are heartened and
+encouraged by the resulting cooperation. However, in the case of
+software used on network servers, this result may fail to come about.
+The GNU General Public License permits making a modified version and
+letting the public access it on a server without ever releasing its
+source code to the public.
+
+ The GNU Affero General Public License is designed specifically to
+ensure that, in such cases, the modified source code becomes available
+to the community. It requires the operator of a network server to
+provide the source code of the modified version running there to the
+users of that server. Therefore, public use of a modified version, on
+a publicly accessible server, gives the public access to the source
+code of the modified version.
+
+ An older license, called the Affero General Public License and
+published by Affero, was designed to accomplish similar goals. This is
+a different license, not a version of the Affero GPL, but Affero has
+released a new version of the Affero GPL which permits relicensing under
+this license.
+
+ The precise terms and conditions for copying, distribution and
+modification follow.
+
+ TERMS AND CONDITIONS
+
+ 0. Definitions.
+
+ "This License" refers to version 3 of the GNU Affero General Public License.
+
+ "Copyright" also means copyright-like laws that apply to other kinds of
+works, such as semiconductor masks.
+
+ "The Program" refers to any copyrightable work licensed under this
+License. Each licensee is addressed as "you". "Licensees" and
+"recipients" may be individuals or organizations.
+
+ To "modify" a work means to copy from or adapt all or part of the work
+in a fashion requiring copyright permission, other than the making of an
+exact copy. The resulting work is called a "modified version" of the
+earlier work or a work "based on" the earlier work.
+
+ A "covered work" means either the unmodified Program or a work based
+on the Program.
+
+ To "propagate" a work means to do anything with it that, without
+permission, would make you directly or secondarily liable for
+infringement under applicable copyright law, except executing it on a
+computer or modifying a private copy. Propagation includes copying,
+distribution (with or without modification), making available to the
+public, and in some countries other activities as well.
+
+ To "convey" a work means any kind of propagation that enables other
+parties to make or receive copies. Mere interaction with a user through
+a computer network, with no transfer of a copy, is not conveying.
+
+ An interactive user interface displays "Appropriate Legal Notices"
+to the extent that it includes a convenient and prominently visible
+feature that (1) displays an appropriate copyright notice, and (2)
+tells the user that there is no warranty for the work (except to the
+extent that warranties are provided), that licensees may convey the
+work under this License, and how to view a copy of this License. If
+the interface presents a list of user commands or options, such as a
+menu, a prominent item in the list meets this criterion.
+
+ 1. Source Code.
+
+ The "source code" for a work means the preferred form of the work
+for making modifications to it. "Object code" means any non-source
+form of a work.
+
+ A "Standard Interface" means an interface that either is an official
+standard defined by a recognized standards body, or, in the case of
+interfaces specified for a particular programming language, one that
+is widely used among developers working in that language.
+
+ The "System Libraries" of an executable work include anything, other
+than the work as a whole, that (a) is included in the normal form of
+packaging a Major Component, but which is not part of that Major
+Component, and (b) serves only to enable use of the work with that
+Major Component, or to implement a Standard Interface for which an
+implementation is available to the public in source code form. A
+"Major Component", in this context, means a major essential component
+(kernel, window system, and so on) of the specific operating system
+(if any) on which the executable work runs, or a compiler used to
+produce the work, or an object code interpreter used to run it.
+
+ The "Corresponding Source" for a work in object code form means all
+the source code needed to generate, install, and (for an executable
+work) run the object code and to modify the work, including scripts to
+control those activities. However, it does not include the work's
+System Libraries, or general-purpose tools or generally available free
+programs which are used unmodified in performing those activities but
+which are not part of the work. For example, Corresponding Source
+includes interface definition files associated with source files for
+the work, and the source code for shared libraries and dynamically
+linked subprograms that the work is specifically designed to require,
+such as by intimate data communication or control flow between those
+subprograms and other parts of the work.
+
+ The Corresponding Source need not include anything that users
+can regenerate automatically from other parts of the Corresponding
+Source.
+
+ The Corresponding Source for a work in source code form is that
+same work.
+
+ 2. Basic Permissions.
+
+ All rights granted under this License are granted for the term of
+copyright on the Program, and are irrevocable provided the stated
+conditions are met. This License explicitly affirms your unlimited
+permission to run the unmodified Program. The output from running a
+covered work is covered by this License only if the output, given its
+content, constitutes a covered work. This License acknowledges your
+rights of fair use or other equivalent, as provided by copyright law.
+
+ You may make, run and propagate covered works that you do not
+convey, without conditions so long as your license otherwise remains
+in force. You may convey covered works to others for the sole purpose
+of having them make modifications exclusively for you, or provide you
+with facilities for running those works, provided that you comply with
+the terms of this License in conveying all material for which you do
+not control copyright. Those thus making or running the covered works
+for you must do so exclusively on your behalf, under your direction
+and control, on terms that prohibit them from making any copies of
+your copyrighted material outside their relationship with you.
+
+ Conveying under any other circumstances is permitted solely under
+the conditions stated below. Sublicensing is not allowed; section 10
+makes it unnecessary.
+
+ 3. Protecting Users' Legal Rights From Anti-Circumvention Law.
+
+ No covered work shall be deemed part of an effective technological
+measure under any applicable law fulfilling obligations under article
+11 of the WIPO copyright treaty adopted on 20 December 1996, or
+similar laws prohibiting or restricting circumvention of such
+measures.
+
+ When you convey a covered work, you waive any legal power to forbid
+circumvention of technological measures to the extent such circumvention
+is effected by exercising rights under this License with respect to
+the covered work, and you disclaim any intention to limit operation or
+modification of the work as a means of enforcing, against the work's
+users, your or third parties' legal rights to forbid circumvention of
+technological measures.
+
+ 4. Conveying Verbatim Copies.
+
+ You may convey verbatim copies of the Program's source code as you
+receive it, in any medium, provided that you conspicuously and
+appropriately publish on each copy an appropriate copyright notice;
+keep intact all notices stating that this License and any
+non-permissive terms added in accord with section 7 apply to the code;
+keep intact all notices of the absence of any warranty; and give all
+recipients a copy of this License along with the Program.
+
+ You may charge any price or no price for each copy that you convey,
+and you may offer support or warranty protection for a fee.
+
+ 5. Conveying Modified Source Versions.
+
+ You may convey a work based on the Program, or the modifications to
+produce it from the Program, in the form of source code under the
+terms of section 4, provided that you also meet all of these conditions:
+
+ a) The work must carry prominent notices stating that you modified
+ it, and giving a relevant date.
+
+ b) The work must carry prominent notices stating that it is
+ released under this License and any conditions added under section
+ 7. This requirement modifies the requirement in section 4 to
+ "keep intact all notices".
+
+ c) You must license the entire work, as a whole, under this
+ License to anyone who comes into possession of a copy. This
+ License will therefore apply, along with any applicable section 7
+ additional terms, to the whole of the work, and all its parts,
+ regardless of how they are packaged. This License gives no
+ permission to license the work in any other way, but it does not
+ invalidate such permission if you have separately received it.
+
+ d) If the work has interactive user interfaces, each must display
+ Appropriate Legal Notices; however, if the Program has interactive
+ interfaces that do not display Appropriate Legal Notices, your
+ work need not make them do so.
+
+ A compilation of a covered work with other separate and independent
+works, which are not by their nature extensions of the covered work,
+and which are not combined with it such as to form a larger program,
+in or on a volume of a storage or distribution medium, is called an
+"aggregate" if the compilation and its resulting copyright are not
+used to limit the access or legal rights of the compilation's users
+beyond what the individual works permit. Inclusion of a covered work
+in an aggregate does not cause this License to apply to the other
+parts of the aggregate.
+
+ 6. Conveying Non-Source Forms.
+
+ You may convey a covered work in object code form under the terms
+of sections 4 and 5, provided that you also convey the
+machine-readable Corresponding Source under the terms of this License,
+in one of these ways:
+
+ a) Convey the object code in, or embodied in, a physical product
+ (including a physical distribution medium), accompanied by the
+ Corresponding Source fixed on a durable physical medium
+ customarily used for software interchange.
+
+ b) Convey the object code in, or embodied in, a physical product
+ (including a physical distribution medium), accompanied by a
+ written offer, valid for at least three years and valid for as
+ long as you offer spare parts or customer support for that product
+ model, to give anyone who possesses the object code either (1) a
+ copy of the Corresponding Source for all the software in the
+ product that is covered by this License, on a durable physical
+ medium customarily used for software interchange, for a price no
+ more than your reasonable cost of physically performing this
+ conveying of source, or (2) access to copy the
+ Corresponding Source from a network server at no charge.
+
+ c) Convey individual copies of the object code with a copy of the
+ written offer to provide the Corresponding Source. This
+ alternative is allowed only occasionally and noncommercially, and
+ only if you received the object code with such an offer, in accord
+ with subsection 6b.
+
+ d) Convey the object code by offering access from a designated
+ place (gratis or for a charge), and offer equivalent access to the
+ Corresponding Source in the same way through the same place at no
+ further charge. You need not require recipients to copy the
+ Corresponding Source along with the object code. If the place to
+ copy the object code is a network server, the Corresponding Source
+ may be on a different server (operated by you or a third party)
+ that supports equivalent copying facilities, provided you maintain
+ clear directions next to the object code saying where to find the
+ Corresponding Source. Regardless of what server hosts the
+ Corresponding Source, you remain obligated to ensure that it is
+ available for as long as needed to satisfy these requirements.
+
+ e) Convey the object code using peer-to-peer transmission, provided
+ you inform other peers where the object code and Corresponding
+ Source of the work are being offered to the general public at no
+ charge under subsection 6d.
+
+ A separable portion of the object code, whose source code is excluded
+from the Corresponding Source as a System Library, need not be
+included in conveying the object code work.
+
+ A "User Product" is either (1) a "consumer product", which means any
+tangible personal property which is normally used for personal, family,
+or household purposes, or (2) anything designed or sold for incorporation
+into a dwelling. In determining whether a product is a consumer product,
+doubtful cases shall be resolved in favor of coverage. For a particular
+product received by a particular user, "normally used" refers to a
+typical or common use of that class of product, regardless of the status
+of the particular user or of the way in which the particular user
+actually uses, or expects or is expected to use, the product. A product
+is a consumer product regardless of whether the product has substantial
+commercial, industrial or non-consumer uses, unless such uses represent
+the only significant mode of use of the product.
+
+ "Installation Information" for a User Product means any methods,
+procedures, authorization keys, or other information required to install
+and execute modified versions of a covered work in that User Product from
+a modified version of its Corresponding Source. The information must
+suffice to ensure that the continued functioning of the modified object
+code is in no case prevented or interfered with solely because
+modification has been made.
+
+ If you convey an object code work under this section in, or with, or
+specifically for use in, a User Product, and the conveying occurs as
+part of a transaction in which the right of possession and use of the
+User Product is transferred to the recipient in perpetuity or for a
+fixed term (regardless of how the transaction is characterized), the
+Corresponding Source conveyed under this section must be accompanied
+by the Installation Information. But this requirement does not apply
+if neither you nor any third party retains the ability to install
+modified object code on the User Product (for example, the work has
+been installed in ROM).
+
+ The requirement to provide Installation Information does not include a
+requirement to continue to provide support service, warranty, or updates
+for a work that has been modified or installed by the recipient, or for
+the User Product in which it has been modified or installed. Access to a
+network may be denied when the modification itself materially and
+adversely affects the operation of the network or violates the rules and
+protocols for communication across the network.
+
+ Corresponding Source conveyed, and Installation Information provided,
+in accord with this section must be in a format that is publicly
+documented (and with an implementation available to the public in
+source code form), and must require no special password or key for
+unpacking, reading or copying.
+
+ 7. Additional Terms.
+
+ "Additional permissions" are terms that supplement the terms of this
+License by making exceptions from one or more of its conditions.
+Additional permissions that are applicable to the entire Program shall
+be treated as though they were included in this License, to the extent
+that they are valid under applicable law. If additional permissions
+apply only to part of the Program, that part may be used separately
+under those permissions, but the entire Program remains governed by
+this License without regard to the additional permissions.
+
+ When you convey a copy of a covered work, you may at your option
+remove any additional permissions from that copy, or from any part of
+it. (Additional permissions may be written to require their own
+removal in certain cases when you modify the work.) You may place
+additional permissions on material, added by you to a covered work,
+for which you have or can give appropriate copyright permission.
+
+ Notwithstanding any other provision of this License, for material you
+add to a covered work, you may (if authorized by the copyright holders of
+that material) supplement the terms of this License with terms:
+
+ a) Disclaiming warranty or limiting liability differently from the
+ terms of sections 15 and 16 of this License; or
+
+ b) Requiring preservation of specified reasonable legal notices or
+ author attributions in that material or in the Appropriate Legal
+ Notices displayed by works containing it; or
+
+ c) Prohibiting misrepresentation of the origin of that material, or
+ requiring that modified versions of such material be marked in
+ reasonable ways as different from the original version; or
+
+ d) Limiting the use for publicity purposes of names of licensors or
+ authors of the material; or
+
+ e) Declining to grant rights under trademark law for use of some
+ trade names, trademarks, or service marks; or
+
+ f) Requiring indemnification of licensors and authors of that
+ material by anyone who conveys the material (or modified versions of
+ it) with contractual assumptions of liability to the recipient, for
+ any liability that these contractual assumptions directly impose on
+ those licensors and authors.
+
+ All other non-permissive additional terms are considered "further
+restrictions" within the meaning of section 10. If the Program as you
+received it, or any part of it, contains a notice stating that it is
+governed by this License along with a term that is a further
+restriction, you may remove that term. If a license document contains
+a further restriction but permits relicensing or conveying under this
+License, you may add to a covered work material governed by the terms
+of that license document, provided that the further restriction does
+not survive such relicensing or conveying.
+
+ If you add terms to a covered work in accord with this section, you
+must place, in the relevant source files, a statement of the
+additional terms that apply to those files, or a notice indicating
+where to find the applicable terms.
+
+ Additional terms, permissive or non-permissive, may be stated in the
+form of a separately written license, or stated as exceptions;
+the above requirements apply either way.
+
+ 8. Termination.
+
+ You may not propagate or modify a covered work except as expressly
+provided under this License. Any attempt otherwise to propagate or
+modify it is void, and will automatically terminate your rights under
+this License (including any patent licenses granted under the third
+paragraph of section 11).
+
+ However, if you cease all violation of this License, then your
+license from a particular copyright holder is reinstated (a)
+provisionally, unless and until the copyright holder explicitly and
+finally terminates your license, and (b) permanently, if the copyright
+holder fails to notify you of the violation by some reasonable means
+prior to 60 days after the cessation.
+
+ Moreover, your license from a particular copyright holder is
+reinstated permanently if the copyright holder notifies you of the
+violation by some reasonable means, this is the first time you have
+received notice of violation of this License (for any work) from that
+copyright holder, and you cure the violation prior to 30 days after
+your receipt of the notice.
+
+ Termination of your rights under this section does not terminate the
+licenses of parties who have received copies or rights from you under
+this License. If your rights have been terminated and not permanently
+reinstated, you do not qualify to receive new licenses for the same
+material under section 10.
+
+ 9. Acceptance Not Required for Having Copies.
+
+ You are not required to accept this License in order to receive or
+run a copy of the Program. Ancillary propagation of a covered work
+occurring solely as a consequence of using peer-to-peer transmission
+to receive a copy likewise does not require acceptance. However,
+nothing other than this License grants you permission to propagate or
+modify any covered work. These actions infringe copyright if you do
+not accept this License. Therefore, by modifying or propagating a
+covered work, you indicate your acceptance of this License to do so.
+
+ 10. Automatic Licensing of Downstream Recipients.
+
+ Each time you convey a covered work, the recipient automatically
+receives a license from the original licensors, to run, modify and
+propagate that work, subject to this License. You are not responsible
+for enforcing compliance by third parties with this License.
+
+ An "entity transaction" is a transaction transferring control of an
+organization, or substantially all assets of one, or subdividing an
+organization, or merging organizations. If propagation of a covered
+work results from an entity transaction, each party to that
+transaction who receives a copy of the work also receives whatever
+licenses to the work the party's predecessor in interest had or could
+give under the previous paragraph, plus a right to possession of the
+Corresponding Source of the work from the predecessor in interest, if
+the predecessor has it or can get it with reasonable efforts.
+
+ You may not impose any further restrictions on the exercise of the
+rights granted or affirmed under this License. For example, you may
+not impose a license fee, royalty, or other charge for exercise of
+rights granted under this License, and you may not initiate litigation
+(including a cross-claim or counterclaim in a lawsuit) alleging that
+any patent claim is infringed by making, using, selling, offering for
+sale, or importing the Program or any portion of it.
+
+ 11. Patents.
+
+ A "contributor" is a copyright holder who authorizes use under this
+License of the Program or a work on which the Program is based. The
+work thus licensed is called the contributor's "contributor version".
+
+ A contributor's "essential patent claims" are all patent claims
+owned or controlled by the contributor, whether already acquired or
+hereafter acquired, that would be infringed by some manner, permitted
+by this License, of making, using, or selling its contributor version,
+but do not include claims that would be infringed only as a
+consequence of further modification of the contributor version. For
+purposes of this definition, "control" includes the right to grant
+patent sublicenses in a manner consistent with the requirements of
+this License.
+
+ Each contributor grants you a non-exclusive, worldwide, royalty-free
+patent license under the contributor's essential patent claims, to
+make, use, sell, offer for sale, import and otherwise run, modify and
+propagate the contents of its contributor version.
+
+ In the following three paragraphs, a "patent license" is any express
+agreement or commitment, however denominated, not to enforce a patent
+(such as an express permission to practice a patent or covenant not to
+sue for patent infringement). To "grant" such a patent license to a
+party means to make such an agreement or commitment not to enforce a
+patent against the party.
+
+ If you convey a covered work, knowingly relying on a patent license,
+and the Corresponding Source of the work is not available for anyone
+to copy, free of charge and under the terms of this License, through a
+publicly available network server or other readily accessible means,
+then you must either (1) cause the Corresponding Source to be so
+available, or (2) arrange to deprive yourself of the benefit of the
+patent license for this particular work, or (3) arrange, in a manner
+consistent with the requirements of this License, to extend the patent
+license to downstream recipients. "Knowingly relying" means you have
+actual knowledge that, but for the patent license, your conveying the
+covered work in a country, or your recipient's use of the covered work
+in a country, would infringe one or more identifiable patents in that
+country that you have reason to believe are valid.
+
+ If, pursuant to or in connection with a single transaction or
+arrangement, you convey, or propagate by procuring conveyance of, a
+covered work, and grant a patent license to some of the parties
+receiving the covered work authorizing them to use, propagate, modify
+or convey a specific copy of the covered work, then the patent license
+you grant is automatically extended to all recipients of the covered
+work and works based on it.
+
+ A patent license is "discriminatory" if it does not include within
+the scope of its coverage, prohibits the exercise of, or is
+conditioned on the non-exercise of one or more of the rights that are
+specifically granted under this License. You may not convey a covered
+work if you are a party to an arrangement with a third party that is
+in the business of distributing software, under which you make payment
+to the third party based on the extent of your activity of conveying
+the work, and under which the third party grants, to any of the
+parties who would receive the covered work from you, a discriminatory
+patent license (a) in connection with copies of the covered work
+conveyed by you (or copies made from those copies), or (b) primarily
+for and in connection with specific products or compilations that
+contain the covered work, unless you entered into that arrangement,
+or that patent license was granted, prior to 28 March 2007.
+
+ Nothing in this License shall be construed as excluding or limiting
+any implied license or other defenses to infringement that may
+otherwise be available to you under applicable patent law.
+
+ 12. No Surrender of Others' Freedom.
+
+ If conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License. If you cannot convey a
+covered work so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you may
+not convey it at all. For example, if you agree to terms that obligate you
+to collect a royalty for further conveying from those to whom you convey
+the Program, the only way you could satisfy both those terms and this
+License would be to refrain entirely from conveying the Program.
+
+ 13. Remote Network Interaction; Use with the GNU General Public License.
+
+ Notwithstanding any other provision of this License, if you modify the
+Program, your modified version must prominently offer all users
+interacting with it remotely through a computer network (if your version
+supports such interaction) an opportunity to receive the Corresponding
+Source of your version by providing access to the Corresponding Source
+from a network server at no charge, through some standard or customary
+means of facilitating copying of software. This Corresponding Source
+shall include the Corresponding Source for any work covered by version 3
+of the GNU General Public License that is incorporated pursuant to the
+following paragraph.
+
+ Notwithstanding any other provision of this License, you have
+permission to link or combine any covered work with a work licensed
+under version 3 of the GNU General Public License into a single
+combined work, and to convey the resulting work. The terms of this
+License will continue to apply to the part which is the covered work,
+but the work with which it is combined will remain governed by version
+3 of the GNU General Public License.
+
+ 14. Revised Versions of this License.
+
+ The Free Software Foundation may publish revised and/or new versions of
+the GNU Affero General Public License from time to time. Such new versions
+will be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+ Each version is given a distinguishing version number. If the
+Program specifies that a certain numbered version of the GNU Affero General
+Public License "or any later version" applies to it, you have the
+option of following the terms and conditions either of that numbered
+version or of any later version published by the Free Software
+Foundation. If the Program does not specify a version number of the
+GNU Affero General Public License, you may choose any version ever published
+by the Free Software Foundation.
+
+ If the Program specifies that a proxy can decide which future
+versions of the GNU Affero General Public License can be used, that proxy's
+public statement of acceptance of a version permanently authorizes you
+to choose that version for the Program.
+
+ Later license versions may give you additional or different
+permissions. However, no additional obligations are imposed on any
+author or copyright holder as a result of your choosing to follow a
+later version.
+
+ 15. Disclaimer of Warranty.
+
+ THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
+APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
+HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
+OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
+THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
+IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
+ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
+
+ 16. Limitation of Liability.
+
+ IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
+THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
+GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
+USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
+DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
+PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
+EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
+SUCH DAMAGES.
+
+ 17. Interpretation of Sections 15 and 16.
+
+ If the disclaimer of warranty and limitation of liability provided
+above cannot be given local legal effect according to their terms,
+reviewing courts shall apply local law that most closely approximates
+an absolute waiver of all civil liability in connection with the
+Program, unless a warranty or assumption of liability accompanies a
+copy of the Program in return for a fee.
+
+ END OF TERMS AND CONDITIONS
+
+ How to Apply These Terms to Your New Programs
+
+ If you develop a new program, and you want it to be of the greatest
+possible use to the public, the best way to achieve this is to make it
+free software which everyone can redistribute and change under these terms.
+
+ To do so, attach the following notices to the program. It is safest
+to attach them to the start of each source file to most effectively
+state the exclusion of warranty; and each file should have at least
+the "copyright" line and a pointer to where the full notice is found.
+
+
+ Copyright (C)
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU Affero General Public License as published
+ by the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU Affero General Public License for more details.
+
+ You should have received a copy of the GNU Affero General Public License
+ along with this program. If not, see .
+
+Also add information on how to contact you by electronic and paper mail.
+
+ If your software can interact with users remotely through a computer
+network, you should also make sure that it provides a way for users to
+get its source. For example, if your program is a web application, its
+interface could display a "Source" link that leads users to an archive
+of the code. There are many ways you could offer source, and different
+solutions will be better for different programs; see section 13 for the
+specific requirements.
+
+ You should also get your employer (if you work as a programmer) or school,
+if any, to sign a "copyright disclaimer" for the program, if necessary.
+For more information on this, and how to apply and follow the GNU AGPL, see
+.
diff --git a/LICENSE.md b/LICENSE.md
deleted file mode 100644
index 4e230a1..0000000
--- a/LICENSE.md
+++ /dev/null
@@ -1,22 +0,0 @@
-MIT License
-
-Copyright (c) 2018 YorkAARGH
-Copyright (c) 2018-2020 mudkipscience
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in all
-copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
-SOFTWARE.
diff --git a/README.md b/README.md
index d0fde98..35cb4cf 100644
--- a/README.md
+++ b/README.md
@@ -1,21 +1,37 @@
# Woomy
-Woomy is a all-purpose discord bot built off the [guidebot](https://github.com/AnIdiotsGuide/guidebot) base and coded in node.js using discord.js.
+
+
+
+
+
-# How to use
-The easiest way to use Woomy is to invite it to your server with [this link.](https://discordapp.com/oauth2/authorize?client_id=435961704145485835&permissions=2134240503&scope=bot) It is hosted 24/7 and automatically updates itself when a new release is made available, making sure you always get the newest features.
+## A feature-rich and configurable Discord bot for music, moderation, currency and more!
-You can also self-host! Some modificatiomns to the code will need to be made before Woomy will run on your machine, but anyone who can read errors will figure out what needs to be changed pretty quickly :P
+**Links**
+* [Official bot invite](https://discord.com/oauth2/authorize?client_id=435961704145485835&permissions=2134240503&scope=bot)
+* [For updates and support join my Discord server!](https://discord.gg/HCF8mdv)
-# Requirements
-- git
-- node.js v12.0.0 or higher
-- node-gyp build tools
-- ffmpeg (or ffmpeg-static)
+## Using Woomy
-# Installation
-- Clone Woomy to your machine
-- Run `npm i` in Woomy's directory
-- Open config.js in your code editor and insert all the required information
+The easiest and recommended way to use Woomy is to invite the official version to your server, which is hosted 24/7 and gets the newest updates as soon as they come out. The invite can be found above, under links. You can also self-host, but no support will be provided to you if you decide to do this.
-# Contributing
-If you wish to contribute to Woomy, please fork the repository and open a pull request. Any contribution is appreciated <3
+## Contributors
+
+Thanks to the following people who have contributed to Woomy:
+
+* [@mudkipscience](https://github.com/mudkipscience/) - Creator and primary developer of Womy
+* [@FLGX](https://github.com/FLGX06/) - Developer, basically wrote the entirety of the music commands and lots of other cool stuff
+* [@TheCakeChicken](https://github.com/TheCakeChicken/) - Developer
+
+And a few other people as well. Check out the [Contributors](https://github.com/mudkipscience/woomy/graphs/contributors) tab!
+
+## Legal stuff
+
+### Using our code
+If you wish to use our code in your project, please credit us! We don't mind you using Woomy's code (it is open source for a reason :P) as long as you dont blatantly copy it and/or refrain from crediting us.
+
+### License
+
+Copyright (C) 2018-2020 Emily J. / mudkipscience and contributors.
+
+Copyrights licensed under the GNU AGPLv3 License, see the accompanying LICENSE file for details.
diff --git a/resources/audio/WOOMY.mp3 b/assets/audio/WOOMY.mp3
similarity index 100%
rename from resources/audio/WOOMY.mp3
rename to assets/audio/WOOMY.mp3
diff --git a/resources/images/attackhelicopter.jpg b/assets/img/attackhelicopter.jpg
similarity index 100%
rename from resources/images/attackhelicopter.jpg
rename to assets/img/attackhelicopter.jpg
diff --git a/resources/images/fax.png b/assets/img/fax.png
similarity index 100%
rename from resources/images/fax.png
rename to assets/img/fax.png
diff --git a/assets/json/8ball.json b/assets/json/8ball.json
new file mode 100644
index 0000000..0590ca3
--- /dev/null
+++ b/assets/json/8ball.json
@@ -0,0 +1,14 @@
+{
+ "responses": [
+ "No darndested clue.",
+ "¯\\_(ツ)_/¯",
+ "Stupid question. You should be ashamed of yourself for even asking.",
+ "Yes!",
+ "Not in your wildest dreams!",
+ "No chance.",
+ "Never.",
+ "Possibly.",
+ "There\"s a high chance.",
+ "I\"d rather not say."
+ ]
+}
\ No newline at end of file
diff --git a/assets/json/coolpeople.json b/assets/json/coolpeople.json
new file mode 100644
index 0000000..86100fa
--- /dev/null
+++ b/assets/json/coolpeople.json
@@ -0,0 +1,21 @@
+{
+ "coolPeople": [
+ "448354605617643520",
+ "433790467830972417",
+ "231777839576252417",
+ "285992938314661899",
+ "231704701433937931",
+ "324937993972350976",
+ "336492042299637771",
+ "273867501006225419",
+ "331870539897372672",
+ "304000458144481280",
+ "239787232666451980",
+ "264970229514371072",
+ "254310746450690048",
+ "358390849807319040",
+ "211011138656272386",
+ "266472557740425216",
+ "102943767346057216"
+ ]
+}
\ No newline at end of file
diff --git a/resources/other/identities.json b/assets/json/identities.json
similarity index 100%
rename from resources/other/identities.json
rename to assets/json/identities.json
diff --git a/resources/other/lyrics.json b/assets/json/lyrics.json
similarity index 100%
rename from resources/other/lyrics.json
rename to assets/json/lyrics.json
diff --git a/resources/other/pronouns.json b/assets/json/pronouns.json
similarity index 100%
rename from resources/other/pronouns.json
rename to assets/json/pronouns.json
diff --git a/assets/json/sexualities.json b/assets/json/sexualities.json
new file mode 100644
index 0000000..2ff29ca
--- /dev/null
+++ b/assets/json/sexualities.json
@@ -0,0 +1,102 @@
+{
+ "aesthetic attraction": {
+ "name": "aesthetic attraction",
+ "description": "Getting pleasure from the appearance of a specific individual like you would from watching beautiful scenery."
+ },
+ "platonic attraction": {
+ "name": "platonic attraction",
+ "description": "A desire to have a platonic relationship or friendship with a specific individual."
+ },
+ "romantic attraction": {
+ "name": "romantic attraction",
+ "description": "A desire to have a romantic relationship with a specific individual."
+ },
+ "sensual attraction": {
+ "name": "sensual attraction",
+ "description": "A desire for physical intimacy with a specific individual. Cuddling, hand holding, etc."
+ },
+ "sexual attraction": {
+ "name": "sexual attraction",
+ "description": "A desire for sexual contact with a specific individual."
+ },
+ "abrosexual": {
+ "name": "abrosexual",
+ "description": "Someone whose sexuality changes frequently. They experience different sexualities over time."
+ },
+ "androgynosexual": {
+ "name": "androgynosexual",
+ "description": "Someone who is attracted to both men and women, particularly those who are androgynous in appearance."
+ },
+ "androsexual": {
+ "name": "androsexual",
+ "description": "Someone who is attracted to men and/or masculine people."
+ },
+ "aromantic": {
+ "name": "aromantic",
+ "description": "Someone who does not experience romantic attraction. They do not have to also be asexual however as they may still experience other types of attraction."
+ },
+ "asexual": {
+ "name": "asexual",
+ "description": "Someone who feels little to no sexual attraction to anyone."
+ },
+ "bisexual": {
+ "name": "bisexual",
+ "description": "Someone who is attracted to more than one gender."
+ },
+ "ceterosexual": {
+ "name": "ceterosexual",
+ "description": "Someone who is attracted to non-binary people."
+ },
+ "demisexual": {
+ "name": "demisexual",
+ "description": "Someone who doesn't experience sexual/romantic attraction towards someone until they form an emotional connection."
+ },
+ "finsexual": {
+ "name": "finsexual",
+ "description": "Someone who is attracted to women and/or feminine people."
+ },
+ "gay": {
+ "name": "gay",
+ "description": "Someone who is homosexual (attracted to ones own gender)"
+ },
+ "gynosexual": {
+ "name": "gynosexual",
+ "description": "Someone who as attracted to women and/or feminity."
+ },
+ "grey-romantic": {
+ "name": "grey-romantic",
+ "description": "Someone with a romantic orentiation that is somewhere between aromantic and romantic."
+ },
+ "heterosexual": {
+ "name": "heterosexual",
+ "description": "Someone who is attracted to people of the opposite gender."
+ },
+ "homosexual": {
+ "name": "homosexual",
+ "description": "Someone attracted to people of ones own gender."
+ },
+ "lesbian": {
+ "name": "lesbian",
+ "description": "A woman who is attracted to other women."
+ },
+ "omnisexual": {
+ "name": "omnisexual",
+ "description": "Someone who is attracted to all genders."
+ },
+ "pansexual": {
+ "name": "pansexual",
+ "description": "Someone who is attracted towards people regardless of their gender identity."
+ },
+ "pomosexual": {
+ "name": "pomosexual",
+ "description": "Someone who does not fit into any sexual orientation label."
+ },
+ "polysexual": {
+ "name": "polysexual",
+ "description": "Someone who is attracted to some, but not all genders."
+ },
+ "straight": {
+ "name": "straight",
+ "description": "Someone who is heterosexual (attracted to people of the opposite gender)"
+ }
+}
\ No newline at end of file
diff --git a/changelog.txt b/changelog.txt
new file mode 100644
index 0000000..59c5536
--- /dev/null
+++ b/changelog.txt
@@ -0,0 +1,13 @@
+Woomy 2.0:
+- A lot of Woomy's code has been rewritten
+- Woomy now uses MongoDB for settings storage instead of enmap
+- Logger now logs which file a log came from
+- Functions file has been separated into multiple helpers
+- Added systemNotice feature, stops Woomy from outputting permission errors and stuff
+- New ping command
+- help command overhauled
+- added `pride` command
+- eval now dm's errors to the user who ran the command
+- ship command overhauled
+- added volume command
+- usage errors are now shown in an embed
\ No newline at end of file
diff --git a/commandTemplate.js b/commandTemplate.js
new file mode 100644
index 0000000..278b134
--- /dev/null
+++ b/commandTemplate.js
@@ -0,0 +1,20 @@
+exports.conf = {
+ enabled: true,
+ guildOnly: false,
+ aliases: [],
+ permLevel: 'User',
+ requiredPerms: [],
+ cooldown: 2000 // miliseconds
+}
+
+exports.help = {
+ name: '',
+ category: '',
+ description: '',
+ usage: '',
+ params: ''
+}
+
+exports.run = async (client, message, args, level, data) => {
+ // epic code goes here
+}
diff --git a/commands/8ball.js b/commands/8ball.js
new file mode 100644
index 0000000..6012c49
--- /dev/null
+++ b/commands/8ball.js
@@ -0,0 +1,25 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: false,
+ aliases: [],
+ permLevel: 'User',
+ requiredPerms: [],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: '8ball',
+ category: 'Fun',
+ description: 'Retrieves an answer to your question from the almighty 8ball.',
+ usage: '`8ball [question]` - Retrieves an answer from 8ball based on the question or sentence provided.',
+ parameters: '`question` - the question you want to ask'
+}
+
+// eslint-disable-next-line no-unused-vars
+const responses = require('../assets/json/8ball.json').responses
+exports.run = async (client, message, args, level, data) => {
+
+ // Finish later
+}
diff --git a/commands/emoji.js b/commands/emoji.js
new file mode 100644
index 0000000..42e0d46
--- /dev/null
+++ b/commands/emoji.js
@@ -0,0 +1,43 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: false,
+ aliases: ['enlarge'],
+ permLevel: 'User',
+ requiredPerms: []
+}
+
+exports.help = {
+ name: 'emoji',
+ category: 'Utility',
+ description: 'Enlarges a custom emoji (cannot be used to enlarge normal emojis)',
+ usage: 'emoji [emoji]',
+ parameters: '`[emoji] - Custom emoji you want to enlarge'
+}
+
+exports.run = async (client, message, args) => {
+ if (!args[0]) {
+ return client.userError(message, exports, 'Missing argument, the `emoji` argument is required!')
+ };
+
+ var ID
+ var format = '.png'
+ var string = args[0].replace(/\D/g, '')
+
+ if (args[0].charAt(1) === 'a' && args[0].charAt(2) === ':') {
+ format = '.gif'
+ };
+
+ if (string.length > 18) {
+ ID = string.slice(string.length - 18)
+ } else {
+ ID = string
+ };
+
+ if (!ID) {
+ return message.channel.send('<:error:466995152976871434> This command only works with custom emojis, sorry ;~;')
+ }
+
+ message.channel.send('https://cdn.discordapp.com/emojis/' + ID + format)
+}
diff --git a/commands/eval.js b/commands/eval.js
new file mode 100644
index 0000000..4e22f1a
--- /dev/null
+++ b/commands/eval.js
@@ -0,0 +1,52 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+/* eslint-disable no-eval */
+
+exports.conf = {
+ enabled: true,
+ guildOnly: false,
+ aliases: [],
+ permLevel: 'Developer',
+ requiredPerms: []
+}
+
+exports.help = {
+ name: 'eval',
+ category: 'Developer',
+ description: 'Evaluates arbitrary javascript.',
+ usage: 'eval [code]',
+ parameters: '`[code] - Javascript code you want to execute.'
+}
+
+exports.run = async (client, message, args, level, data) => {
+ const hastebin = require('hastebin-gen')
+ const code = args.join(' ')
+ try {
+ const evaled = eval(code)
+ const clean = await client.clean(client, evaled)
+
+ if (clean.length > 2000) {
+ hastebin(clean, { extension: 'txt' }).then(haste => {
+ return message.channel.send('`OUTPUT`\n' + haste)
+ }).catch(error => {
+ client.logger.error(error)
+ })
+
+ return
+ }
+ message.channel.send(`\`OUTPUT\` \`\`\`js\n${await clean}\n\`\`\``)
+ } catch (err) {
+ const errclean = await client.clean(client, err)
+ if (errclean.length > 2000) {
+ hastebin(errclean, { extension: 'txt' }).then(haste => {
+ return message.channel.send('`ERROR`\n' + haste)
+ }).catch(error => {
+ client.logger.error(error)
+ })
+
+ return
+ }
+ message.author.send(`\`ERROR\` \`\`\`xl\n${await errclean}\n\`\`\``)
+ message.react('⚠️')
+ }
+}
diff --git a/commands/help.js b/commands/help.js
new file mode 100644
index 0000000..beadd92
--- /dev/null
+++ b/commands/help.js
@@ -0,0 +1,103 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: false,
+ aliases: ['commands', 'cmds'],
+ permLevel: 'User',
+ requiredPerms: ['EMBED_LINKS'],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: 'help',
+ category: 'Bot',
+ description: 'Lists all commands Woomy has, what they do, and how to use them.',
+ usage: '`help` - Shows the embed that provides info on how to use woomy. `help all` - Lists all commands.\n`help ` - Show detailed information on how to use the specified command.',
+ parameters: '`command` - The name of the command you want more information on.'
+}
+
+const Discord = require('discord.js')
+exports.run = (client, message, args, level, data) => {
+ const embed = new Discord.MessageEmbed()
+ embed.setColor(client.embedColour(message.guild))
+
+ const commands = client.commands
+ const categories = []
+
+ commands.forEach((cmd) => {
+ if (!categories.includes(cmd.help.category)) {
+ if (cmd.help.category === 'Developer' && !client.config.devs.includes('message.author.id')) {
+ return
+ }
+ categories.push(cmd.help.category)
+ }
+ })
+
+ if (!args[0]) {
+ let uPrefix = '`' + data.user.prefix + '`'
+ let gPrefix = ''
+
+ if (client.config.defaultPrefix === data.user.prefix) {
+ uPrefix = 'None set, use: `~myprefix'
+ }
+
+ if (message.guild) {
+ gPrefix = 'Server Prefix: `' + data.guild.prefix + '`'
+
+ if (client.config.defaultPrefix === data.guild.prefix) {
+ gPrefix = 'Server Prefix: None set, use: `~prefix`'
+ }
+ }
+
+ embed.setTitle('Help & Commands')
+ embed.setDescription('')
+ if (client.version.news.length > 0) {
+ embed.addField('**News**', client.version.news)
+ }
+ embed.addField('**Prefixes**', `Default Prefix: \`${client.config.defaultPrefix}\`\nUser Prefix: ${uPrefix}\nServer Prefix: ${gPrefix}`)
+ embed.addField('**Command Syntax**', 'For arguments in commands:\n» Arguments in `[]` brackets are required.\n» Arguments in `<>` brackets are optional.\n» Arguments prefixed with `-` are flags, and are placed at the start of the command (`avatar -jpg mudkipscience`)')
+ embed.addField('**Commands**', `Use \`${message.prefix}help all\` to view all commands, or \`${message.prefix}help \` for more information on a specific command.\n\n[Bot Invite](https://discord.com/oauth2/authorize?client_id=${client.user.id}&permissions=2134240503&scope=bot) | [Discord Server](https://discord.gg/HCF8mdv) | [GitHub](https://github.com/mudkipscience/woomy) | [Vote for me!](https://top.gg/bot/435961704145485835/vote)`)
+
+ return message.channel.send(embed)
+ } else if (args[0] === 'all') {
+ embed.setTitle('Commands')
+ categories.sort().forEach((cat) => {
+ const filtered = commands.filter((cmd) => cmd.help.category === cat)
+ embed.addField('**' + cat + '**', filtered.map((cmd) => '`' + cmd.help.name + '`').join(', '))
+ })
+
+ if (message.guild && data.guild.customCommands.length > 0) {
+ embed.addField('**Custom**', data.guild.customCommands.map((cmd) => '`' + cmd.name + '`').join(' '))
+ }
+
+ return message.channel.send(embed)
+ } else {
+ const command = args.shift().toLowerCase()
+ const cmd = commands.get(command) || commands.get(client.aliases.get(command))
+ if (!cmd) {
+ return message.channel.send('Command/alias doesn\'t exist')
+ }
+
+ let aliases = ''
+
+ if (cmd.conf.aliases.length > 0) {
+ aliases = '`' + cmd.conf.aliases.join('`, `') + '`'
+ }
+
+ embed.setTitle(`${cmd.help.category} -> ${cmd.help.name}`)
+ embed.setDescription(cmd.help.description)
+ embed.addField('**Usage**', cmd.help.usage)
+ if (cmd.help.parameters.length > 0) {
+ embed.addField('**Parameters**', cmd.help.parameters)
+ }
+ if (aliases) {
+ embed.addField('**Aliases**', aliases)
+ }
+ embed.addField('**Rank required**', cmd.conf.permLevel, true)
+ embed.addField('**Server only**', cmd.conf.guildOnly, true)
+ embed.addField('**Cooldown**', cmd.conf.cooldown / 1000 + ' seconds', true)
+ embed.setFooter('< > = optional, [ ] = required. Don\'t include the brackets in the command itself!')
+ message.channel.send(embed)
+ }
+}
diff --git a/commands/invite.js b/commands/invite.js
new file mode 100644
index 0000000..e23d1e6
--- /dev/null
+++ b/commands/invite.js
@@ -0,0 +1,22 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: false,
+ aliases: [],
+ permLevel: 'User',
+ requiredPerms: [],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: 'invite',
+ category: 'Bot',
+ description: 'Sends a link to my support/development server.',
+ usage: 'invite',
+ parameters: ''
+}
+
+exports.run = async (client, message, args, level, data) => {
+ message.channel.send(`Here you go! I hope you enjoy using me ^-^\n`)
+}
diff --git a/commands/level.js b/commands/level.js
new file mode 100644
index 0000000..ca11482
--- /dev/null
+++ b/commands/level.js
@@ -0,0 +1,27 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: false,
+ aliases: ['plevel', 'permlevel'],
+ permLevel: 'User',
+ requiredPerms: [],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: 'level',
+ category: 'Bot',
+ description: 'Returns your permission level.',
+ usage: 'level',
+ parameters: ''
+}
+
+exports.run = async (client, message, args, level, data) => {
+ try {
+ const friendly = client.config.permLevels.find(l => l.level === level).name
+ message.reply(`Your permission level is: ${friendly} (${level})`)
+ } catch (err) {
+ message.channel.send('There was an error!\n' + err).catch()
+ }
+}
diff --git a/commands/movehere.js b/commands/movehere.js
new file mode 100644
index 0000000..eb2d4cd
--- /dev/null
+++ b/commands/movehere.js
@@ -0,0 +1,36 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: true,
+ aliases: [],
+ permLevel: 'User',
+ requiredPerms: ['CONNECT', 'SPEAK'],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: 'movehere',
+ category: 'Music',
+ description: 'Moves music related messages to the channel the this command is ran in.',
+ usage: 'movehere',
+ parameters: ''
+}
+
+const music = require('../utils/music')
+exports.run = async (client, message, args, level, data) => {
+ // get guild music data
+ const guild = music.getGuild(message.guild.id)
+
+ if (!guild.playing) {
+ return message.channel.send('<:error:466995152976871434> Nothing is playing.')
+ }
+
+ if (guild.channel.id === message.channel.id) {
+ return message.channel.send('<:error:466995152976871434> Music messages are already being sent to this channel.')
+ }
+
+ guild.channel = message.channel
+
+ message.channel.send('<:success:466995111885144095> Music messages will now be sent to this channel.')
+}
diff --git a/commands/movesong.js b/commands/movesong.js
new file mode 100644
index 0000000..4645952
--- /dev/null
+++ b/commands/movesong.js
@@ -0,0 +1,60 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: true,
+ aliases: [],
+ permLevel: 'User',
+ requiredPerms: [],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: 'movesong',
+ category: 'Music',
+ description: 'Moves a song to a new position in the queue.',
+ usage: 'movesong [current position] [new position]',
+ parameters: '[current position] - The current position of the song you want to move'
+}
+
+const { getGuild } = require('../utils/music')
+module.exports.run = (client, message, args, level) => {
+ const queue = getGuild(message.guild.id).queue
+
+ if (queue.length < 3) {
+ return message.channel.send('<:error:466995152976871434> Not enough songs are in the queue for this command to work!')
+ }
+
+ if (!args[0]) {
+ return client.userError(message, exports, 'Missing argument, the `current position` argument is required!')
+ }
+
+ if (!args[1]) {
+ return client.userError(message, exports, 'Missing argument, the `new position` argument is required!')
+ }
+
+ const oldPosition = +args[0]
+ const newPosition = +args[1]
+
+ if (isNaN(oldPosition) === true) {
+ return message.channel.send('<:error:466995152976871434> That isn\'t a number! You need to tell me the songs position in the queue (1, 2, etc.)')
+ }
+
+ if (isNaN(newPosition) === true) {
+ return message.channel.send('<:error:466995152976871434> That isn\'t a number! You need to tell me the songs position in the queue (1, 2, etc.)')
+ }
+
+ if (oldPosition < 1 || oldPosition >= queue.length) {
+ return message.channel.send('<:error:466995152976871434> Old position is not a valid song ID.')
+ }
+
+ if (newPosition < 1 || newPosition >= queue.length) {
+ return message.channel.send('<:error:466995152976871434> New position is not a valid song ID.')
+ }
+
+ const songName = queue[oldPosition].video.title
+
+ queue.splice(newPosition, 0, queue.splice(oldPosition, 1)[0])
+
+ message.channel.send(`<:success:466995111885144095> Moved **${songName}** from position \`${oldPosition}\` to \`${newPosition}\``)
+}
diff --git a/commands/myprefix.js b/commands/myprefix.js
new file mode 100644
index 0000000..b0b5a4a
--- /dev/null
+++ b/commands/myprefix.js
@@ -0,0 +1,36 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: false,
+ aliases: [],
+ permLevel: 'User',
+ requiredPerms: [],
+ cooldown: 2000 // miliseconds
+}
+
+exports.help = {
+ name: 'myprefix',
+ category: 'Settings',
+ description: 'Shows or changes the prefix Woomy uses for you.',
+ usage: '`myprefix` ',
+ parameters: ''
+}
+
+exports.run = async (client, message, args, level, data) => {
+ const prefix = args.join(' ')
+
+ if (!prefix) {
+ return message.channel.send(`Your current prefix is: \`${data.user.prefix}\``)
+ }
+
+ if (prefix.toLowerCase() === 'reset') {
+ await client.updateUser(message.author, { prefix: client.config.defaultPrefix })
+
+ return message.channel.send('Your prefix has been reset.')
+ }
+
+ await client.updateUser(message.author, { prefix: prefix })
+
+ message.channel.send(`Your prefix has been updated: \`${prefix}\``)
+}
diff --git a/commands/nowplaying.js b/commands/nowplaying.js
new file mode 100644
index 0000000..b3e51b4
--- /dev/null
+++ b/commands/nowplaying.js
@@ -0,0 +1,47 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: true,
+ aliases: ['np'],
+ permLevel: 'User',
+ requiredPerms: ['EMBED_LINKS'],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: 'nowplaying',
+ category: 'Music',
+ description: 'Gives details on the song that is currently playing',
+ usage: 'nowplaying',
+ parameters: ''
+}
+
+const { getGuild, createTimestamp } = require('../utils/music')
+const { MessageEmbed } = require('discord.js')
+exports.run = async (client, message, args, level, data) => {
+ const guild = getGuild(message.guild.id)
+
+ if (guild.queue.length < 1) {
+ return message.channel.send(client.config.emojis.error + ' Nothing is in the queue!')
+ }
+
+ const s = guild.queue[0]
+ const elapsedTime = createTimestamp(guild.dispatcher.streamTime / 1000)
+ let timestamp = `\`[${createTimestamp(s.video.lengthSeconds)}]\``
+
+ if (timestamp !== '`[LIVE]`') {
+ timestamp = `\`[${elapsedTime + '/' + createTimestamp(s.video.lengthSeconds)}]\``
+ }
+
+ const embed = new MessageEmbed()
+ embed.setTitle('Now playing')
+ embed.setThumbnail(s.video.videoThumbnails[1].url)
+ embed.setColor(client.embedColour(message.guild))
+ embed.setDescription(`**[${s.video.title}](https://www.youtube.com/watch?v=${s.video.videoId})**`)
+ embed.addField('Channel:', s.video.author, true)
+ embed.addField('Time:', timestamp, true)
+ embed.setFooter('Requested by ' + s.requestedBy.tag, s.requestedBy.avatarURL({ format: 'png', dynamic: true, size: 2048 }))
+
+ message.channel.send(embed)
+}
diff --git a/commands/pause.js b/commands/pause.js
new file mode 100644
index 0000000..a8b4f22
--- /dev/null
+++ b/commands/pause.js
@@ -0,0 +1,37 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: true,
+ aliases: [],
+ permLevel: 'User',
+ requiredPerms: [],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: 'pause',
+ category: 'Music',
+ description: 'Pauses the music that is currently playing.',
+ usage: 'pause',
+ parameters: ''
+}
+
+const { getGuild } = require('../utils/music')
+exports.run = async (client, message, args, level, data) => {
+ const guild = getGuild(message.guild.id)
+
+ if (guild.paused === true) {
+ return message.channel.send('<:error:466995152976871434> The music has already been paused! Run resume to start the music again.')
+ }
+
+ if (guild.queue.length < 1 || guild.playing === false) {
+ return message.channel.send('<:error:466995152976871434> Nothing is playing!')
+ }
+
+ guild.playing = false
+ guild.paused = true
+ guild.dispatcher.pause()
+
+ message.channel.send('<:pause:467639357961142273> Music playback has been paused.')
+}
diff --git a/commands/ping.js b/commands/ping.js
new file mode 100644
index 0000000..451b017
--- /dev/null
+++ b/commands/ping.js
@@ -0,0 +1,25 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: false,
+ aliases: [],
+ permLevel: 'User',
+ requiredPerms: [],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: 'ping',
+ category: 'Bot',
+ description: 'Check if bot is dying.',
+ usage: 'ping',
+ parameters: ''
+}
+
+exports.run = async (client, message, args, level, data) => {
+ const msg = await message.channel.send('Pinging...')
+ msg.edit(
+ `Pong! \`${msg.createdTimestamp - message.createdTimestamp}ms\` (💗 \`${Math.round(client.ws.ping)}ms\`)`
+ )
+}
diff --git a/commands/play.js b/commands/play.js
new file mode 100644
index 0000000..bf5ca8b
--- /dev/null
+++ b/commands/play.js
@@ -0,0 +1,23 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: true,
+ aliases: [],
+ permLevel: 'User',
+ requiredPerms: ['CONNECT', 'SPEAK'],
+ cooldown: 5000
+}
+
+exports.help = {
+ name: 'play',
+ category: 'Music',
+ description: 'Plays the song you request, or adds it to the queue.',
+ usage: 'playnext [song]',
+ parameters: '[song] - The name or youtube URL of the song you want to play.'
+}
+
+const { play } = require('../utils/music')
+exports.run = async (client, message, args, level, data) => {
+ await play(client, data.guild.music, message, args.join(' '), false)
+}
diff --git a/commands/playnext.js b/commands/playnext.js
new file mode 100644
index 0000000..71afda9
--- /dev/null
+++ b/commands/playnext.js
@@ -0,0 +1,23 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: true,
+ aliases: [],
+ permLevel: 'User',
+ requiredPerms: ['CONNECT', 'SPEAK'],
+ cooldown: 5000
+}
+
+exports.help = {
+ name: 'playnext',
+ category: 'Music',
+ description: 'Similar to play, but adds it to the start of the queue instead of the end.',
+ usage: 'playnext [song]',
+ parameters: '[song] - The name or youtube URL of the song you want to play.'
+}
+
+const { play } = require('../utils/music')
+exports.run = async (client, message, args, level, data) => {
+ await play(client, data.guild.music, message, args.join(' '), true)
+}
diff --git a/commands/prefix.js b/commands/prefix.js
new file mode 100644
index 0000000..270552d
--- /dev/null
+++ b/commands/prefix.js
@@ -0,0 +1,36 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: false,
+ aliases: [],
+ permLevel: 'User',
+ requiredPerms: [],
+ cooldown: 2000 // miliseconds
+}
+
+exports.help = {
+ name: 'prefix',
+ category: 'Settings',
+ description: 'Shows or changes the prefix Woomy uses for this server.',
+ usage: 'prefix ',
+ params: ''
+}
+
+exports.run = async (client, message, args, level, data) => {
+ const prefix = args.join(' ')
+
+ if (!prefix) {
+ return message.channel.send(`Current server prefix: \`${data.guild.prefix}\``)
+ }
+
+ if (prefix.toLowerCase() === 'reset') {
+ await client.updateGuild(message.guild, { prefix: client.config.defaultPrefix })
+
+ return message.channel.send('Server prefix has been reset.')
+ }
+
+ await client.updateGuild(message.guild, { prefix: prefix })
+
+ message.channel.send(`The server prefix has been updated: \`${prefix}\``)
+}
diff --git a/commands/pride.js b/commands/pride.js
new file mode 100644
index 0000000..e1e06ed
--- /dev/null
+++ b/commands/pride.js
@@ -0,0 +1,50 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: false,
+ aliases: [],
+ permLevel: 'User',
+ requiredPerms: ['ATTACH_FILES'],
+ cooldown: 15000
+}
+
+exports.help = {
+ name: 'pride',
+ category: 'Fun',
+ description: 'Adds a pride flag ring to your avatar. Available flags are lesbian, gay, bisexual, pansexual, trans, asexual, aromantic and ally.',
+ usage: '`pride [flag]` - Adds a pride flag overlay to your avatar.\n`pride -g [flag]` - Adds a pride flag gradient on your avatar.',
+ parameters: '`flag` - What flag you want to add to your avatar (options listed above)\n`-g` - Add this to the start of the command to turn the flag into a gradient.'
+}
+
+const url = 'https://demirramon.com/gen/pride.png'
+const Discord = require('discord.js')
+exports.run = (client, message, args) => {
+ const flag = args[0]
+ if (!flag) {
+ return client.userError(message, exports, 'Missing argument, the `flag` argument is required!')
+ }
+
+ const available = ['lesbian', 'gay', 'bisexual', 'pansexual', 'trans', 'asexual', 'aromantic', 'ally']
+
+ if (!available.includes(flag.toLowerCase())) {
+ return message.channel.send(`This flag isn't available, sorry ;~;\nAvailable flags: \`${available.join('`, `')}\``)
+ }
+
+ let gradient = 'false'
+ if (message.flags.includes('g')) {
+ gradient = 'true'
+ }
+
+ message.channel.startTyping()
+
+ const params = `image=${message.author.avatarURL({ format: 'png', size: 2048 })}&flag=${flag.toLowerCase()}&full=true&gradient=${gradient}&background=false&fit=true&v=2019-08-07`
+
+ try {
+ message.channel.stopTyping()
+ message.channel.send({ files: [new Discord.MessageAttachment(url + '?' + params)] })
+ } catch (err) {
+ message.channel.stopTyping()
+ message.channel.send(`<:error:466995152976871434> Error when generating image: \`${err}\``)
+ }
+}
diff --git a/commands/queue.js b/commands/queue.js
new file mode 100644
index 0000000..1471564
--- /dev/null
+++ b/commands/queue.js
@@ -0,0 +1,178 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+'use strict'
+
+exports.conf = {
+ enabled: true,
+ guildOnly: true,
+ aliases: [],
+ permLevel: 'User',
+ requiredPerms: [],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: 'queue',
+ category: 'Music',
+ description: 'Lists all songs that have been queued.',
+ usage: 'queue ',
+ parameters: ''
+}
+
+const { getGuild, createTimestamp } = require('../utils/music')
+const Discord = require('discord.js')
+exports.run = (client, message, args) => {
+ var queue = getGuild(message.guild.id).queue
+
+ if (queue.length < 1) {
+ return message.channel.send('<:error:466995152976871434> Nothing is playing.')
+ }
+
+ const lists = []
+
+ function generateList (start, number) {
+ let list = ''
+ let timestamp
+
+ if (start === 1 && queue.length === 1) {
+ return ['There\'s nothing else waiting to be played!', 1]
+ }
+
+ if (number === 1 && queue.length + 1 < start) {
+ return false
+ }
+
+ const q = queue.slice(start)
+
+ let i = 0
+
+ for (i = 0; i < q.length; i++) {
+ const song = q[i]
+
+ timestamp = createTimestamp(song.video.lengthSeconds)
+
+ const aaa = list + `\`${(i + 1) + start - 1}:\` **[${song.video.title}](https://www.youtube.com/watch?v=${song.video.videoId})** added by ${song.requestedBy} \`[${timestamp}]\`\n`
+
+ if (aaa.length > 1024) {
+ return [list, start + i - 1]
+ } else {
+ list = aaa
+ }
+
+ // totalDuration = totalDuration + song.duration
+ }
+
+ return [list, start + i + 1]
+ }
+
+ const songsInQueue = queue.length - 1
+ let songsInQueueEnglish = 'song'
+
+ function generatePage (list, page) {
+ if (!list || list === '') {
+ return false
+ }
+
+ var embed = new Discord.MessageEmbed()
+ embed.setTitle(`Queue for: ${message.guild.name}`)
+ embed.setColor(client.embedColour(message.guild))
+
+ var elapsedTime = getGuild(message.guild.id).dispatcher.streamTime / 1000
+ var totalDuration = queue[0].video.lengthSeconds - elapsedTime
+
+ let timeRemaining = ''
+
+ for (let i = 1; i < queue.length; i++) {
+ const b = queue[i]
+
+ if (b.video.lengthSeconds === 0) {
+ timeRemaining = '∞'
+
+ break
+ }
+
+ totalDuration += b.video.lengthSeconds
+ }
+
+ if (timeRemaining === '') {
+ const queueDuration = createTimestamp(totalDuration)
+
+ timeRemaining = queueDuration
+ }
+
+ let timestamp = `\`${createTimestamp(queue[0].video.lengthSeconds)}\``
+
+ if (timestamp !== '`[LIVE]`') {
+ timestamp = `\`[${createTimestamp(elapsedTime) + '/' + createTimestamp(queue[0].video.lengthSeconds)}]\``
+ }
+
+ embed.addField('Now playing:', `**[${queue[0].video.title}](https://www.youtube.com/watch?v=${queue[0].video.videoId})** added by ${queue[0].requestedBy} ${timestamp}`)
+
+ embed.addField('Up next:', list)
+
+ if (songsInQueue > 1 || songsInQueue === 0) {
+ songsInQueueEnglish = 'songs'
+ }
+
+ embed.setFooter(`Page ${page}/${lists.length} | ${songsInQueue + ' ' + songsInQueueEnglish} in queue | ${timeRemaining} time remaining`)
+
+ return embed
+ }
+
+ var myMessage = null
+
+ function displayPage (number) {
+ const page = generatePage(lists[number - 1], number)
+
+ if (page) {
+ if (myMessage) {
+ myMessage.edit(page)
+ } else {
+ myMessage = message.channel.send(page)
+ }
+
+ return true
+ } else {
+ return false
+ }
+ }
+
+ function aFunction (start) {
+ // start - index of song, which we should start with
+ // end - index of song, which we ended with
+
+ const [list, end] = generateList(start, lists.length + 1)
+
+ if (list && list !== '') {
+ lists.push(list)
+
+ if (queue[end + 1]) {
+ aFunction(end + 1)
+ }
+ }
+ }
+
+ aFunction(1)
+
+ let page = 1
+
+ if (args[0]) {
+ const userPage = Number(args[0])
+
+ if (userPage) {
+ page = userPage
+ } else {
+ return message.channel.send(
+ `<:error:466995152976871434> Invalid page. Usage: \`${client.commands.get('queue').help.usage}\``
+ )
+ }
+ }
+
+ if (displayPage(page)) {
+
+ } else {
+ return message.channel.send(
+ `<:error:466995152976871434> Page ${page} doesn't exist!`
+ )
+ }
+}
diff --git a/commands/reload.js b/commands/reload.js
new file mode 100644
index 0000000..3de7af1
--- /dev/null
+++ b/commands/reload.js
@@ -0,0 +1,32 @@
+exports.conf = {
+ enabled: true,
+ guildOnly: false,
+ aliases: [],
+ permLevel: 'Developer',
+ requiredPerms: [],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: 'reload',
+ category: 'Developer',
+ description: 'Reloads a command without having to restart the whole bot.',
+ usage: 'reload [command]',
+ parameters: '[command] - command you want to reload'
+}
+
+exports.run = async (client, message, args) => { // eslint-disable-line no-unused-vars
+ if (!args || args.length < 1) {
+ return message.channel.send(
+ `<:error:466995152976871434> You must provide a command to reload! Usage: \`${client.commands.get('reload').help.usage}\``
+ )
+ }
+
+ let response = await client.unloadCommand(args[0])
+ if (response) return message.channel.send(`<:error:466995152976871434> Error unloading: ${response}`)
+
+ response = client.loadCommand(args[0])
+ if (response) return message.channel.send(`<:error:466995152976871434> Error loading: ${response}`)
+
+ message.channel.send(`<:success:466995111885144095> \`${args[0]}\` has been reloaded!`)
+}
diff --git a/commands/removesong.js b/commands/removesong.js
new file mode 100644
index 0000000..63a5891
--- /dev/null
+++ b/commands/removesong.js
@@ -0,0 +1,47 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: true,
+ aliases: [],
+ permLevel: 'User',
+ requiredPerms: [],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: 'removesong',
+ category: 'Music',
+ description: 'Removes a song from the queue.',
+ usage: 'removesong [position]',
+ parameters: '[position] - The position of the song you want to remove'
+}
+
+const { getGuild } = require('../utils/music')
+module.exports.run = (client, message, args, level) => {
+ var queue = getGuild(message.guild.id).queue
+
+ if (queue.length < 2) {
+ return message.channel.send('<:error:466995152976871434> Not enough songs are in the queue for this command to work!')
+ }
+
+ if (!args[0]) {
+ return message.channel.send(`<:error:466995152976871434> You didn't tell me what song to remove! Usage: \`${client.commands.get('removesong').help.usage}\``)
+ }
+
+ var input = +args[0]
+
+ if (isNaN(input) === true) {
+ return message.channel.send('<:error:466995152976871434> That isn\'t a number! You need to tell me the songs position in the queue (1, 2, etc.)')
+ }
+
+ if (input >= queue.length || input < 1) {
+ return message.channel.send('<:error:466995152976871434> Input is not a valid song ID.')
+ }
+
+ var songName = queue[input].video.title
+
+ queue.splice(input, 1)
+
+ message.channel.send(`<:success:466995111885144095> Removed from queue: **${songName}**`)
+}
diff --git a/commands/restart.js b/commands/restart.js
new file mode 100644
index 0000000..05bc222
--- /dev/null
+++ b/commands/restart.js
@@ -0,0 +1,30 @@
+exports.conf = {
+ enabled: true,
+ guildOnly: false,
+ aliases: [],
+ permLevel: 'Developer',
+ requiredPerms: [],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: 'restart',
+ category: 'Developer',
+ description: 'Restarts the bot.',
+ usage: 'restart',
+ parameters: ''
+}
+
+exports.run = async (client, message) => { // eslint-disable-line no-unused-vars
+ // This actually shuts down the bot, you'll need to use something like pm2 to get it to restart
+
+ await message.channel.send('<:reboot:467216876938985482> Restarting...')
+
+ /*
+ client.commands.forEach( async cmd => {
+ await client.unloadCommand(cmd);
+ });
+ */
+
+ process.exit(1)
+}
diff --git a/commands/resume.js b/commands/resume.js
new file mode 100644
index 0000000..96aa05c
--- /dev/null
+++ b/commands/resume.js
@@ -0,0 +1,37 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: true,
+ aliases: ['unpause'],
+ permLevel: 'User',
+ requiredPerms: [],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: 'resume',
+ category: 'Music',
+ description: 'Starts music back up if it was paused.',
+ usage: 'resume',
+ parameters: ''
+}
+
+const { getGuild } = require('../utils/music')
+exports.run = async (client, message, args, level, data) => {
+ const guild = getGuild(message.guild.id)
+
+ if (guild.paused === false) {
+ return message.channel.send('<:error:466995152976871434> The music is already playing, use pause to pause the music first!')
+ }
+
+ if (guild.queue.length < 1) {
+ return message.channel.send('<:error:466995152976871434> Nothing is playing!')
+ }
+
+ guild.playing = true
+ guild.paused = false
+ guild.dispatcher.resume()
+
+ message.channel.send('<:success:466995111885144095> Music playback has been resumed.')
+}
diff --git a/commands/ship.js b/commands/ship.js
new file mode 100644
index 0000000..e156e6c
--- /dev/null
+++ b/commands/ship.js
@@ -0,0 +1,71 @@
+
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: false,
+ aliases: [],
+ permLevel: 'User',
+ requiredPerms: [],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: 'ship',
+ category: 'Fun',
+ description: 'Ship two people together <3',
+ usage: 'ship `[name1]` `[name2]`',
+ parameters: '`name1` The name of the first person you want to ship.\n `name` The name of the second person you want to ship.'
+}
+
+const { MessageEmbed } = require('discord.js')
+exports.run = async (client, message, args, level, data) => {
+ var rating = Math.floor(Math.random() * 100) + 1
+ var meter = ['▬', '▬', '▬', '▬', '▬', '▬', '▬', '▬', '▬']
+ var hearts = [
+ '❤️',
+ '🧡',
+ '💛',
+ '💚',
+ '💙',
+ '💜'
+ ]
+
+ if (!args[0]) {
+ return message.channel.send(client.userError(exports, 'Missing argument, the `name1` argument is required!'))
+ }
+
+ if (!args[1]) {
+ return message.channel.send(client.userError(exports, 'Missing argument, the `name2` argument is required!'))
+ }
+
+ const firstName = args[0]
+ const secondName = args[1]
+
+ const shipName = firstName.substr(0, firstName.length * 0.5) + secondName.substr(secondName.length * 0.5)
+
+ if (shipName.toLowerCase() === 'teily' || shipName.toLowerCase() === 'emrra') {
+ rating = '100'
+ }
+
+ var pos = 0
+ var under = 9
+ while (pos < 10) {
+ if (rating < under) {
+ meter.splice(pos, 0, hearts.random())
+ break
+ }
+ pos++
+ under += 10
+ }
+
+ if (rating >= 99) {
+ meter.splice(9, 0, hearts.random())
+ }
+
+ const embed = new MessageEmbed()
+ embed.setTitle(`Original Names: ${firstName}, ${secondName}`)
+ embed.setColor(client.embedColour(message.guild))
+ embed.setDescription(`Ship Name: **${shipName}**\nCompatibility: **${rating}%**\n**[**${meter.join('')}**]**`)
+ message.channel.send(embed)
+}
diff --git a/commands/shuffle.js b/commands/shuffle.js
new file mode 100644
index 0000000..0c81e1c
--- /dev/null
+++ b/commands/shuffle.js
@@ -0,0 +1,38 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: true,
+ aliases: [],
+ permLevel: 'User',
+ requiredPerms: [],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: 'shuffle',
+ category: 'Music',
+ description: 'Mixes up the songs in the queue',
+ usage: 'shuffle',
+ parameters: ''
+}
+
+const { getGuild } = require('../utils/music')
+module.exports.run = (client, message, args, level) => {
+ var queue = getGuild(message.guild.id).queue
+
+ if (queue.length < 4) {
+ return message.channel.send('<:error:466995152976871434> There aren\'t enough songs are in the queue for this command to work!')
+ }
+
+ const max = queue.length - 1
+ const min = 1
+ for (let i = max; i >= min; i--) {
+ const randomIndex = Math.floor(Math.random() * (max - min + 1)) + min
+ const itemAtIndex = queue[randomIndex]
+ queue[randomIndex] = queue[i]
+ queue[i] = itemAtIndex
+ }
+
+ message.channel.send('<:success:466995111885144095> Queue shuffled!')
+}
diff --git a/commands/skip.js b/commands/skip.js
new file mode 100644
index 0000000..c55c061
--- /dev/null
+++ b/commands/skip.js
@@ -0,0 +1,25 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: true,
+ aliases: [],
+ permLevel: 'User',
+ requiredPerms: [],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: 'skip',
+ category: 'Music',
+ description: 'Force skips currently playing song.',
+ usage: 'skip',
+ params: ''
+}
+
+const { skip } = require('../utils/music')
+exports.run = async (client, message, args, level, data) => {
+ skip(message.guild, 'skip')
+
+ message.reply('<:success:466995111885144095> Song skipped.')
+}
diff --git a/commands/stop.js b/commands/stop.js
new file mode 100644
index 0000000..ccad10d
--- /dev/null
+++ b/commands/stop.js
@@ -0,0 +1,35 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: true,
+ aliases: [],
+ permLevel: 'User',
+ requiredPerms: [],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: 'stop',
+ category: 'Music',
+ description: 'Stops music, clears the queue and disconnects from the voice channel.',
+ usage: 'stop',
+ params: ''
+}
+
+const { getGuild } = require('../utils/music')
+exports.run = async (client, message) => {
+ const guild = getGuild(message.guild.id)
+
+ if (guild.queue.length < 1 || !guild.playing || !guild.dispatcher) return message.channel.send('Nothing is playing.')
+ if (!message.member.voice.channel) return message.channel.send('You need to be in voice channel to use this command!')
+
+ guild.dispatcher.end('silent')
+
+ guild.queue = []
+ guild.playing = false
+ guild.paused = false
+ guild.skippers = []
+
+ message.channel.send('Playback stopped!')
+}
diff --git a/commands/support.js b/commands/support.js
new file mode 100644
index 0000000..b696986
--- /dev/null
+++ b/commands/support.js
@@ -0,0 +1,22 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: false,
+ aliases: [],
+ permLevel: 'User',
+ requiredPerms: [],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: 'support',
+ category: 'Bot',
+ description: 'Sends a link to my support/development server.',
+ usage: 'support',
+ parameters: ''
+}
+
+exports.run = async (client, message, args, level, data) => {
+ message.channel.send('Here you go! Hopefully we can help you here :3 https://discord.gg/HCF8mdv')
+}
diff --git a/commands/volume.js b/commands/volume.js
new file mode 100644
index 0000000..78b5a33
--- /dev/null
+++ b/commands/volume.js
@@ -0,0 +1,45 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: true,
+ aliases: ['vol'],
+ permLevel: 'User',
+ requiredPerms: [],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: 'volume',
+ category: 'Music',
+ description: 'Sets volume of currently playing music. (100% = 25% of the actual volume)',
+ usage: 'volume [volume]',
+ parameters: '[volume] - Target volume from 0-100%'
+}
+
+const { setVolume } = require('../utils/music')
+exports.run = async (client, message, args, level, data) => {
+ let userVolume
+
+ if (args[0].includes('%')) {
+ userVolume.replace('%', '')
+ }
+
+ userVolume = +userVolume
+
+ if (isNaN(userVolume) === true) {
+ return message.channel.send('<:error:466995152976871434> Input must be a number!')
+ }
+
+ if (userVolume) {
+ userVolume = Number(userVolume)
+
+ userVolume = userVolume / 100 * 0.25
+
+ if (userVolume <= 1) {
+ setVolume(message.guild, userVolume)
+
+ message.reply('<:success:466995111885144095> Set volume to ' + userVolume * 100 + '%')
+ }
+ }
+}
diff --git a/commands/voteskip.js b/commands/voteskip.js
new file mode 100644
index 0000000..6792b8c
--- /dev/null
+++ b/commands/voteskip.js
@@ -0,0 +1,67 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+exports.conf = {
+ enabled: true,
+ guildOnly: true,
+ aliases: [],
+ permLevel: 'User',
+ requiredPerms: [],
+ cooldown: 2000
+}
+
+exports.help = {
+ name: 'voteskip',
+ category: 'Music',
+ description: 'Vote to skip the currently playing song.',
+ usage: 'voteskip',
+ params: ''
+}
+
+const { skip, getGuild } = require('../utils/music')
+exports.run = (client, message, args, level) => {
+ const guild = getGuild(message.guild.id)
+
+ if (guild.queue.length < 1 || !guild.playing || !guild.dispatcher) {
+ return message.channel.send(
+ '<:error:466995152976871434> Nothing is playing.'
+ )
+ }
+
+ const vc = message.guild.members.cache.get(client.user.id).voice.channel
+
+ if (vc !== message.member.voice.channel) {
+ return message.channel.send(
+ '<:error:466995152976871434> You need to be in my voice channel to use this command!'
+ )
+ }
+
+ if (guild.queue[0].requestedBy.id === message.author.id) {
+ skip(message.guild, 'skip')
+
+ message.channel.send(
+ '<:success:466995111885144095> Song has been skipped by the user who requested it.'
+ )
+
+ return
+ }
+
+ if (guild.skippers.indexOf(message.author.id) === -1) {
+ guild.skippers.push(message.author.id)
+
+ if (guild.skippers.length >= Math.ceil(vc.members.filter(member => !member.user.bot).size / 2)) {
+ skip(message.guild, 'skip')
+
+ message.channel.send(
+ '<:skip:467216735356059660> Song skipped.'
+ )
+ } else {
+ message.channel.send(
+ `<:success:466995111885144095> Your vote has been acknowledged! **${guild.skippers.length + '/' + Math.ceil(vc.members.filter(member => !member.user.bot).size / 2)}**`
+ )
+ };
+ } else {
+ message.channel.send(
+ '<:denied:466995195150336020> You cannot vote twice!'
+ )
+ }
+}
diff --git a/configTemplate.js b/configTemplate.js
index b6e96c3..cb4d4fc 100644
--- a/configTemplate.js
+++ b/configTemplate.js
@@ -1,75 +1,103 @@
const config = {
- // ID's
- "owners": [], // Adding your ID here will give you access to dangerous commands like eval. Please be careful with who you add here! Eval can be used to modify the host machine.
+ // Discord tokens
+ token: '',
+ devtoken: '',
- // Host options
- "devmodeEnabled": false, // true or false
- "loggingServer": "", // server ID, or blank to disable
- "startupLogs": "", // Channel ID, or blank to disable
- "consoleLogs": "", // Channel ID, or blank to disable
+ // Bot name
+ botName: '',
- // Tokens
- "token": "", // Your bot's token.
- "devtoken": "", // (optional) another token, meant for a bot used for development
- "ytkey": "", // Youtube API key, needed for music searching to work
- "dblkey": "", // top.gg key, sends bot statistics to top.gg. You do not need this.
-
- // Default per-server settings
- "defaultSettings" : {
- "prefix": "~",
- "devprefix": "!",
- "modRole": "None set",
- "adminRole": "None set",
- "mutedRole": "None set",
- "autorole": "off",
- "welcomeChannel": "off",
- "welcomeMessage": "off",
- "leaveMessage": "off",
- "chatlogsChannel": "off",
- "modlogsChannel": "off",
- "raidMode": "off",
- "raidModeStrict": "off",
- "blacklisted": "ARRAY",
- "botChannels": "ARRAY",
- "AFK": "ARRAY",
- "SAR": "ARRAY",
- "customCommands": "ARRAY",
+ // Auto-update from git (WIP)
+ autoUpdate: {
+ enabled: false, // enable auto-update
+ branch: 'next', // git branch
+ autoFetch: false, // check if an update is available and automatically restart and update
+ fetchInterval: 60000 // auto-fetch interval in milliseconds
},
- // Perm levels
+ // API keys that are required for some features/commands
+ keys: {
+ dbl: '', // top.gg key
+ sentry: '' // sentry.io dsn
+ },
+
+ // Configurable API endpoints
+ endpoints: {
+ invidious: 'https://invidious.snopyta.org/api/'
+ },
+
+ // Users added to this embed get access to developer-level commands
+ devs: [''],
+
+ // ID for the support server and the various channels Woomy logs to (leave blank if not used)
+ support: {
+ id: '',
+ logs: '',
+ startupLogs: '',
+ serverLogs: ''
+ },
+
+ // URL of MongoDB database
+ mongoDB: 'mongodb://localhost:27017/woomy',
+
+ // Default prefix Woomy uses
+ defaultPrefix: '~',
+
+ // Emojis used by Woomy
+ emojis: {
+ success: '',
+ error: '',
+ denied: '',
+ search: '',
+ crown: '',
+ boost: '',
+ bot: '',
+ status: {
+ online: '',
+ idle: '',
+ dnd: '',
+ offline: ''
+ }
+ },
+
+ // Permission levels
permLevels: [
- { level: 0,
- name: "User",
+ {
+ level: 0,
+ name: 'User',
check: () => true
},
- { level: 1,
- name: "Moderator",
+ {
+ level: 1,
+ name: 'Moderator',
check: (message) => {
try {
- if (message.member.roles.cache.has(message.settings.modRole)) return true;
+ if (message.member.roles.cache.has(message.settings.modRole)) return true
} catch (e) {
- return false;
+ return false
}
}
},
- { level: 2,
- name: "Administrator",
+ {
+ level: 2,
+ name: 'Administrator',
check: (message) => {
try {
- if (message.member.roles.cache.has(message.settings.adminRole) || message.member.permissions.has("ADMINISTRATOR")) return true;
+ if (message.member.roles.cache.has(message.settings.adminRole) || message.member.permissions.has('ADMINISTRATOR')) return true
} catch (e) {
- return false;
+ return false
}
}
},
- { level: 3,
- name: "Server Owner",
- check: (message) => message.channel.type === "text" ? (message.guild.ownerID === message.author.id ? true : false) : false
- },
+ {
+ level: 3,
+ name: 'Server Owner',
+
+ check: (message) => message.channel.type === 'text' ? (message.guild.ownerID === message.author.id) : false
+ }
]
-};
+}
-module.exports = config;
+module.exports = config
diff --git a/events/disconnect.js b/events/disconnect.js
new file mode 100644
index 0000000..ca34fed
--- /dev/null
+++ b/events/disconnect.js
@@ -0,0 +1,5 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+module.exports = (client) => {
+ client.logger.warn('Lost connection to Discord.')
+}
diff --git a/events/error.js b/events/error.js
new file mode 100644
index 0000000..884dd55
--- /dev/null
+++ b/events/error.js
@@ -0,0 +1,5 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+module.exports = async (client, error) => {
+ client.logger.error(JSON.stringify(error.stack))
+}
diff --git a/events/guildCreate.js b/events/guildCreate.js
new file mode 100644
index 0000000..822489c
--- /dev/null
+++ b/events/guildCreate.js
@@ -0,0 +1,22 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+const Discord = require('discord.js')
+module.exports = async (client, guild) => {
+ client.logger.info('Guild joined.')
+
+ // Create DB entry for newly joined guild
+ try {
+ await client.findOrCreateGuild(guild)
+ } catch (err) {
+ client.logger.error('Failed to create DB entry for newly joined guild: ' + err)
+ }
+
+ if (client.devmode === false) {
+ const channel = client.channels.cache.get(client.config.support.serverLogs)
+ // check if has perms, channel exists
+ const embed = new Discord.MessageEmbed()
+ embed.setColor('#F38159')
+ embed.setDescription(`Joined a new server with \`${guild.members.cache.size}\` members! I'm now in \`${client.guilds.cache.size}\` servers.`)
+ channel.send(embed)
+ }
+}
diff --git a/events/guildDelete.js b/events/guildDelete.js
new file mode 100644
index 0000000..18a3539
--- /dev/null
+++ b/events/guildDelete.js
@@ -0,0 +1,23 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+const Discord = require('discord.js')
+module.exports = async (client, guild) => {
+ if (!guild.available) return
+
+ client.logger.info('Guild left.')
+
+ // Delete this guild's data from our database
+ try {
+ await client.deleteGuild(guild)
+ } catch (err) {
+ client.logger.error('Failed to delete DB entry for guild: ' + err)
+ }
+
+ if (client.devmode === false) {
+ const channel = client.channels.cache.get(client.config.support.serverLogs)
+ const embed = new Discord.MessageEmbed()
+ embed.setColor('#9494FF')
+ embed.setDescription(`Left a server. I'm now in \`${client.guilds.cache.size}\` servers.`)
+ channel.send(embed)
+ }
+}
diff --git a/events/message.js b/events/message.js
new file mode 100644
index 0000000..6a26bee
--- /dev/null
+++ b/events/message.js
@@ -0,0 +1,126 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+module.exports = async (client, message) => {
+ if (message.author.bot) return
+
+ const data = {}
+
+ data.user = await client.findOrCreateUser(message.author)
+
+ const prefixes = [data.user.prefix]
+
+ if (message.guild) {
+ data.guild = await client.findOrCreateGuild(message.guild)
+ prefixes.push(data.guild.prefix)
+ }
+
+ prefixes.push(`<@${client.user.id}> `, `<@!${client.user.id}> `)
+
+ let prefix
+
+ for (const thisPrefix of prefixes) {
+ if (message.content.startsWith(thisPrefix)) prefix = thisPrefix
+ }
+
+ if (message.content.indexOf(prefix) !== 0) return
+
+ if (prefix === `<@${client.user.id}> ` || prefix === `<@!${client.user.id}> `) {
+ message.prefix = '@Woomy '
+ } else {
+ message.prefix = prefix
+ }
+
+ const args = message.content.slice(prefix.length).trim().split(/ +/g)
+ const command = args.shift().toLowerCase()
+
+ if (message.guild && !message.member) await message.guild.fetchMember(message.author)
+
+ const level = client.permlevel(message, data.guildSettings)
+
+ const cmd = client.commands.get(command) || client.commands.get(client.aliases.get(command))
+ if (!cmd) return
+
+ if (message.guild) {
+ if (!message.channel.permissionsFor(client.user).has('SEND_MESSAGES')) {
+ try {
+ return message.author.send(`I don't have permission to speak in \`#${message.channel.name}\`, Please ask a moderator to give me the send messages permission!`)
+ } catch (err) {}
+ }
+
+ if (data.guild.disabledCommands.includes(cmd.help.name)) {
+ if (data.guild.systemNotice.enabled === true) {
+ return message.channel.send('This command has been disabled in this server.')
+ }
+ }
+
+ if (data.guild.disabledCategories.includes(cmd.help.category)) {
+ if (data.guild.systemNotice.enabled === true) {
+ return message.channel.send('This category has been disabled in this server.')
+ }
+ }
+ }
+
+ if (!cmd.conf.enabled) {
+ if (data.guild.systemNotice.enabled === true) {
+ return message.channel.send('This command has been disabled by my developers.')
+ } else {
+ return
+ }
+ }
+
+ if (cmd && !message.guild && cmd.conf.guildOnly) {
+ return message.channel.send('This command is unavailable in direct messages! Please run this command in a server.')
+ }
+
+ if (message.guild) {
+ var missing = cmd.conf.requiredPerms.filter(p => !message.channel.permissionsFor(client.user).has(p))
+ if (missing.length > 0) {
+ missing = '`' + (missing.join('`, `')) + '`'
+ return message.channel.send(`Missing permissions: ${missing}`)
+ }
+ }
+
+ // Dev perm level is separate so dev's don't get owner perms where they shouldn't have them
+ if (cmd.conf.permLevel === 'Developer') {
+ if (!client.config.devs.includes(message.author.id)) {
+ if (data.guild.systemNotice.enabled === true) {
+ return message.channel.send('You don\'t have permission to run this command!')
+ } else {
+ return
+ }
+ }
+ }
+
+ if (level < client.levelCache[cmd.conf.permLevel]) {
+ if (data.guild.systemNotice.enabled === true) {
+ return message.channel.send('You don\'t have permission to run this command!')
+ } else {
+ return
+ }
+ }
+
+ // Cooldown
+ if (client.cooldown.get(cmd.help.name).has(message.author.id)) {
+ const init = client.cooldown.get(command).get(message.author.id)
+ const curr = new Date()
+ const diff = Math.round((curr - init) / 1000)
+ const time = cmd.conf.cooldown / 1000
+ return message.reply(`this command is on cooldown! You'll be able to use it again in ${time - diff} seconds.`)
+ } else {
+ client.cooldown.get(cmd.help.name).set(message.author.id, new Date())
+
+ setTimeout(() => {
+ client.cooldown.get(cmd.help.name).delete(message.author.id)
+ }, client.commands.get(cmd.help.name).conf.cooldown)
+ }
+
+ message.author.permLevel = level
+
+ message.flags = []
+ while (args[0] && args[0][0] === '-') {
+ message.flags.push(args.shift().slice(1))
+ }
+ client.logger.cmd(`Command ran: ${cmd.help.name}`)
+
+ cmd.run(client, message, args, level, data)
+}
diff --git a/events/ready.js b/events/ready.js
new file mode 100644
index 0000000..0a3bc3a
--- /dev/null
+++ b/events/ready.js
@@ -0,0 +1,29 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+const moment = require('moment')
+module.exports = (client) => {
+ const timestamp = moment().format('YYYY-MM-DD HH:mm:ss')
+ const activities = client.commands.keyArray()
+ let activity = activities.random()
+
+ client.user.setActivity(`${client.config.defaultPrefix + activity} | v${client.version.number}`, { type: 'PLAYING' })
+
+ setInterval(() => {
+ activity = activities.random()
+ if (client.lockActivity === false) {
+ client.user.setActivity(`${client.config.defaultPrefix + activity} | v${client.version.number}`, { type: 'PLAYING' })
+ };
+ }, 20000)
+
+ // REMOVE ! IN FRONT OF CLIENT.CONFIG.SUPPORT.ID WHEN DEVMODE WORKS
+
+ if (!client.config.support.id && client.config.support.startupLogs && client.devmode === false) {
+ try {
+ const guild = client.guilds.cache.get(client.config.support.id)
+ const channel = guild.channels.cache.get(client.config.support.startupLogs)
+ channel.send(`Bot started at \`${timestamp}\``)
+ } catch (err) {}
+ }
+
+ client.logger.ready('Connected to Discord as ' + client.user.tag)
+}
diff --git a/events/reconnecting.js b/events/reconnecting.js
new file mode 100644
index 0000000..768e0c8
--- /dev/null
+++ b/events/reconnecting.js
@@ -0,0 +1,5 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+module.exports = (client) => {
+ client.logger.info('Reconnecting to Discord...')
+}
diff --git a/events/voiceStateUpdate.js b/events/voiceStateUpdate.js
new file mode 100644
index 0000000..9d9afa9
--- /dev/null
+++ b/events/voiceStateUpdate.js
@@ -0,0 +1,48 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+const music = require('../utils/music')
+
+module.exports = (client, oldState, newState) => {
+ if (newState.channelID !== oldState.channelID) {
+ const guild = music.getGuild(newState.guild.id)
+
+ // Reset queue, dispatcher, etc if Woomy is forcibly disconnected from the queue
+ if (guild.voiceChannel && !guild.voiceChannel.members.get(client.user.id) && guild.queue.length > 0) {
+ guild.queue = []
+ guild.playing = false
+ guild.paused = false
+ guild.skippers = []
+ }
+
+ // Auto-disconnect feature
+ if (guild.playing && guild.channel && guild.voiceChannel.id === oldState.channelID) {
+ if (guild.voiceChannel.members.filter(member => !member.user.bot).size < 1) {
+ guild.autoDisconnect = true
+
+ guild.message.channel.send(`The music will end in 2 minutes if nobody rejoins **${guild.voiceChannel.name}**`)
+ .then(msg => {
+ msg.delete({ timeout: 120000 })
+ })
+
+ setTimeout(() => {
+ if (guild.dispatcher !== null && guild.voiceChannel.members.filter(member => !member.user.bot).size < 1 && guild.autoDisconnect) {
+ // Probably should be async? But no need here I think
+ guild.dispatcher.end('silent')
+
+ guild.queue = []
+ guild.playing = false
+ guild.paused = false
+ guild.dispatcher = null
+ guild.skippers = []
+
+ guild.message.channel.send('The music has ended because no one was listening to me ;~;')
+ } else {
+ guild.autoDisconnect = false
+ }
+ }, 120000)
+ } else {
+ guild.autoDisconnect = false
+ }
+ }
+ }
+}
diff --git a/index.js b/index.js
index 49d5326..e6cc82a 100644
--- a/index.js
+++ b/index.js
@@ -1,93 +1,122 @@
-if (Number(process.version.slice(1).split(".")[0]) < 12) {
- throw new Error("Node 12.0.0 or higher is required. Please update Node on your system.");
-};
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
-const Discord = require('discord.js');
-const { promisify } = require('util');
-const readdir = promisify(require('fs').readdir);
-const Enmap = require('enmap');
-const chalk = require('chalk');
-const client = new Discord.Client();
+'use strict'
-try {
- client.config = require('./config');
-} catch (err) {
- console.log('Failed to load config.js:', err);
- process.exit();
-};
+// remove this after we uncomment sentry
+/* eslint-disable no-unused-vars */
-try{
- client.version = require('./version.json');
-} catch (err) {
- console.log('Failed to load version.json:', err);
- process.exit();
-};
+// Check node.js version
+if (Number(process.version.slice(1).split('.')[0]) < 12) {
+ console.log('NodeJS 12.0.0 or higher is required. Please update NodeJS on your system.')
+ process.exit()
+}
-try{
- client.logger = require('./src/modules/Logger');
-} catch (err) {
- console.log('Failed to load Logger.js:', err);
- process.exit();
-};
+// Libraries
+const Discord = require('discord.js')
+const fs = require('fs')
+const isDocker = require('is-docker')
+const sentry = require('@sentry/node')
-client.logger.setClient(client);
+// Create bot client instance
+const client = new Discord.Client({ disabledEvents: ['TYPING_START'] })
-try{
- require("./src/modules/functions")(client);
-} catch (err) {
- console.log('Failed to load functions.js:', err);
- process.exit();
-};
+// Load all our useful utilities
+client.configTemplate = require('./configTemplate')
+client.config = require('./config')
+client.version = require('./version.json')
+client.db = require('./utils/mongoose')
+client.logger = require('./utils/logger')
+require('./utils/_functions')(client)
-if(client.config.devmodeEnabled == true && process.env['USER'] != 'container') {
- client.devmode = true;
-} else {
- client.devmode = false;
- if(client.config.dblkey.length > 0) {
- const DBL = require("dblapi.js");
- const dblapi = new DBL(client.config.dblkey, client);
- };
-};
+// Set missing values in config from config template
+for (const c in client.configTemplate) {
+ if (typeof client.config[c] === 'undefined') {
+ client.logger.warn('Config value missing: ' + String(c))
+ client.config[c] = client.configTemplate[c]
+ }
+}
-client.commands = new Enmap();
-client.aliases = new Enmap();
-client.settings = new Enmap({name: 'settings'});
-
-const init = async () => {
- const cmdFiles = await readdir("./src/commands/");
- client.logger.info(`Loading ${cmdFiles.length} commands.`);
- cmdFiles.forEach(file => {
- if (!file.endsWith(".js")) {
- return;
- };
- const response = client.loadCommand(file);
- if (response) {
- console.log(response);
- };
- });
-
- const evtFiles = await readdir("./src/events/");
- client.logger.info(`Loading ${evtFiles.length} events.`);
- evtFiles.forEach(file => {
- if (!file.endsWith(".js")) {
- return;
- };
- const eventName = file.split(".")[0];
- const event = require(`./src/events/${file}`);
- client.on(eventName, event.bind(null, client));
- });
-
- client.levelCache = {};
- for (let i = 0; i < client.config.permLevels.length; i++) {
- const thisLevel = client.config.permLevels[i];
- client.levelCache[thisLevel.name] = thisLevel.level;
- };
-
- if(client.devmode === true) {
- client.login(client.config.devtoken);
+if (typeof client.config.devmode !== 'undefined') { // Check if devmode is explicitly overridden
+ client.devmode = client.config.devmode
+} else { // Check if Woomy is running inside a Docker container
+ if (isDocker() === false) {
+ client.devmode = true
} else {
- client.login(client.config.token);
- };
-};
+ client.devmode = false
+ }
+}
-init();
\ No newline at end of file
+if (client.devmode) {
+ client.logger.warn('Running in development mode.')
+}
+
+// Create caches for permissions, commands, cooldowns and aliases
+client.levelCache = {}
+client.commands = new Discord.Collection()
+client.cooldown = new Discord.Collection()
+client.aliases = new Discord.Collection()
+
+// Main initialisation function
+const init = async () => {
+ // initialise sentry
+ if (client.config.keys.sentry !== '' && client.devmode === false) {
+ // sentry.init({ dsn: client.config.keys.sentry })
+ }
+
+ // Command handler
+ fs.readdir('./commands', (err, files) => {
+ if (err) {
+ client.logger.error('Failed to get files in commands directory: ' + err)
+ process.exit()
+ }
+ client.logger.info(`Loading ${files.length} commands.`)
+ files.forEach(file => {
+ if (!file.endsWith('.js')) {
+ return
+ }
+ const res = client.loadCommand(file)
+ if (res) {
+ client.logger.error(res)
+ }
+ })
+ })
+
+ // Event handler
+ fs.readdir('./events', (err, files) => {
+ if (err) {
+ client.logger.error('Failed to get files in events directory: ' + err)
+ process.exit()
+ }
+ client.logger.info(`Loading ${files.length} events.`)
+ files.forEach(file => {
+ if (!file.endsWith('.js')) {
+ return
+ }
+ const event = require(`./events/${file}`)
+ client.on(file.substr(0, file.length - 3), event.bind(null, client))
+ })
+ })
+
+ // Cache client permissions
+ for (let i = 0; i < client.config.permLevels.length; i++) {
+ const thisLevel = client.config.permLevels[i]
+ client.levelCache[thisLevel.name] = thisLevel.level
+ }
+
+ // Initialise DB
+ await client.db.init(client)
+
+ // Login to Discord
+ function failedToLogin (err) {
+ client.logger.error('Couldn\'t login: ' + err)
+ process.exit(0)
+ }
+
+ if (client.devmode !== true) {
+ client.login(client.config.token).catch(failedToLogin)
+ } else {
+ client.login(client.config.devtoken).catch(failedToLogin)
+ }
+}
+
+init()
diff --git a/models/guild.js b/models/guild.js
new file mode 100644
index 0000000..9482faf
--- /dev/null
+++ b/models/guild.js
@@ -0,0 +1,98 @@
+const { Schema, model } = require('mongoose')
+const { defaultPrefix } = require('../config')
+
+module.exports = model('Guild', new Schema({
+ _id: Schema.Types.ObjectId,
+ guildID: String,
+
+ prefix: {
+ type: String,
+ default: defaultPrefix
+ },
+
+ modRole: {
+ type: String,
+ default: null
+ },
+
+ adminRole: {
+ type: String,
+ default: null
+ },
+
+ mutedRole: {
+ type: String,
+ default: null
+ },
+
+ autoRole: {
+ type: String,
+ default: null
+ },
+
+ systemNotice: {
+ type: Object,
+ default: {
+ enabled: true,
+ autoDelete: 0
+ }
+ },
+
+ music: {
+ type: Object,
+ default: {
+ defaultVolume: 0.25
+ }
+ },
+
+ plugins: {
+ type: Object,
+ default: {
+ welcome: {
+ enabled: false,
+ channel: null,
+ message: null
+ },
+ goodbye: {
+ enabled: false,
+ channel: null,
+ message: null
+ },
+ chatLogs: {
+ enabled: false,
+ channel: null
+ },
+ modLogs: {
+ enabled: false,
+ channel: null
+ }
+ }
+ },
+
+ botChannels: {
+ type: Array,
+ default: []
+ },
+
+ blacklisted: {
+ type: Array,
+ default: []
+ },
+
+ customCommands: {
+ type: Array,
+ default: []
+ },
+
+ disabledCommands: {
+ type: Array,
+ default: []
+ },
+
+ disabledCategories: {
+ type: Array,
+ default: []
+ }
+}))
+
+// I SPWENT TWO FUCKONG DAUYS TRYING TO FIGURE OUT HOW TO UPDATE EXISTING DB ENTRIES WITH NEW SCHEMA SHIT AND IT DOES THIS BY FUCKING DEFAULT
diff --git a/models/member.js b/models/member.js
new file mode 100644
index 0000000..9a367c8
--- /dev/null
+++ b/models/member.js
@@ -0,0 +1,8 @@
+const { Schema, model } = require('mongoose')
+
+module.exports = model('Member', new Schema({
+ _id: Schema.Types.ObjectId,
+ userID: String
+
+ // Will chuck in some stuff like timed mutes, warning system, levelling, etc
+}))
diff --git a/models/user.js b/models/user.js
new file mode 100644
index 0000000..5400bd7
--- /dev/null
+++ b/models/user.js
@@ -0,0 +1,28 @@
+const { Schema, model } = require('mongoose')
+const { defaultPrefix } = require('../config')
+
+module.exports = model('User', new Schema({
+ _id: Schema.Types.ObjectId,
+ userID: String,
+
+ prefix: {
+ type: String,
+ default: defaultPrefix
+ },
+
+ profile: {
+ type: Object,
+ default: {
+ bio: 'I should run ~setbio :P',
+ birthdate: null,
+ pronouns: null,
+ favColour: null
+ }
+ },
+
+ // polyamory uwu
+ marriages: {
+ type: Array,
+ default: []
+ }
+}))
diff --git a/package-lock.json b/package-lock.json
new file mode 100644
index 0000000..b01e384
--- /dev/null
+++ b/package-lock.json
@@ -0,0 +1,3436 @@
+{
+ "name": "woomy",
+ "version": "2.0.0",
+ "lockfileVersion": 1,
+ "requires": true,
+ "dependencies": {
+ "@babel/code-frame": {
+ "version": "7.8.3",
+ "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.8.3.tgz",
+ "integrity": "sha512-a9gxpmdXtZEInkCSHUJDLHZVBgb1QS0jhss4cPP93EW7s+uC5bikET2twEF3KV+7rDblJcmNvTR7VJejqd2C2g==",
+ "requires": {
+ "@babel/highlight": "^7.8.3"
+ }
+ },
+ "@babel/core": {
+ "version": "7.9.0",
+ "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.9.0.tgz",
+ "integrity": "sha512-kWc7L0fw1xwvI0zi8OKVBuxRVefwGOrKSQMvrQ3dW+bIIavBY3/NpXmpjMy7bQnLgwgzWQZ8TlM57YHpHNHz4w==",
+ "requires": {
+ "@babel/code-frame": "^7.8.3",
+ "@babel/generator": "^7.9.0",
+ "@babel/helper-module-transforms": "^7.9.0",
+ "@babel/helpers": "^7.9.0",
+ "@babel/parser": "^7.9.0",
+ "@babel/template": "^7.8.6",
+ "@babel/traverse": "^7.9.0",
+ "@babel/types": "^7.9.0",
+ "convert-source-map": "^1.7.0",
+ "debug": "^4.1.0",
+ "gensync": "^1.0.0-beta.1",
+ "json5": "^2.1.2",
+ "lodash": "^4.17.13",
+ "resolve": "^1.3.2",
+ "semver": "^5.4.1",
+ "source-map": "^0.5.0"
+ },
+ "dependencies": {
+ "semver": {
+ "version": "5.7.1",
+ "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz",
+ "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ=="
+ }
+ }
+ },
+ "@babel/generator": {
+ "version": "7.9.5",
+ "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.9.5.tgz",
+ "integrity": "sha512-GbNIxVB3ZJe3tLeDm1HSn2AhuD/mVcyLDpgtLXa5tplmWrJdF/elxB56XNqCuD6szyNkDi6wuoKXln3QeBmCHQ==",
+ "requires": {
+ "@babel/types": "^7.9.5",
+ "jsesc": "^2.5.1",
+ "lodash": "^4.17.13",
+ "source-map": "^0.5.0"
+ }
+ },
+ "@babel/helper-function-name": {
+ "version": "7.9.5",
+ "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.9.5.tgz",
+ "integrity": "sha512-JVcQZeXM59Cd1qanDUxv9fgJpt3NeKUaqBqUEvfmQ+BCOKq2xUgaWZW2hr0dkbyJgezYuplEoh5knmrnS68efw==",
+ "requires": {
+ "@babel/helper-get-function-arity": "^7.8.3",
+ "@babel/template": "^7.8.3",
+ "@babel/types": "^7.9.5"
+ }
+ },
+ "@babel/helper-get-function-arity": {
+ "version": "7.8.3",
+ "resolved": "https://registry.npmjs.org/@babel/helper-get-function-arity/-/helper-get-function-arity-7.8.3.tgz",
+ "integrity": "sha512-FVDR+Gd9iLjUMY1fzE2SR0IuaJToR4RkCDARVfsBBPSP53GEqSFjD8gNyxg246VUyc/ALRxFaAK8rVG7UT7xRA==",
+ "requires": {
+ "@babel/types": "^7.8.3"
+ }
+ },
+ "@babel/helper-member-expression-to-functions": {
+ "version": "7.8.3",
+ "resolved": "https://registry.npmjs.org/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.8.3.tgz",
+ "integrity": "sha512-fO4Egq88utkQFjbPrSHGmGLFqmrshs11d46WI+WZDESt7Wu7wN2G2Iu+NMMZJFDOVRHAMIkB5SNh30NtwCA7RA==",
+ "requires": {
+ "@babel/types": "^7.8.3"
+ }
+ },
+ "@babel/helper-module-imports": {
+ "version": "7.8.3",
+ "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.8.3.tgz",
+ "integrity": "sha512-R0Bx3jippsbAEtzkpZ/6FIiuzOURPcMjHp+Z6xPe6DtApDJx+w7UYyOLanZqO8+wKR9G10s/FmHXvxaMd9s6Kg==",
+ "requires": {
+ "@babel/types": "^7.8.3"
+ }
+ },
+ "@babel/helper-module-transforms": {
+ "version": "7.9.0",
+ "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.9.0.tgz",
+ "integrity": "sha512-0FvKyu0gpPfIQ8EkxlrAydOWROdHpBmiCiRwLkUiBGhCUPRRbVD2/tm3sFr/c/GWFrQ/ffutGUAnx7V0FzT2wA==",
+ "requires": {
+ "@babel/helper-module-imports": "^7.8.3",
+ "@babel/helper-replace-supers": "^7.8.6",
+ "@babel/helper-simple-access": "^7.8.3",
+ "@babel/helper-split-export-declaration": "^7.8.3",
+ "@babel/template": "^7.8.6",
+ "@babel/types": "^7.9.0",
+ "lodash": "^4.17.13"
+ }
+ },
+ "@babel/helper-optimise-call-expression": {
+ "version": "7.8.3",
+ "resolved": "https://registry.npmjs.org/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.8.3.tgz",
+ "integrity": "sha512-Kag20n86cbO2AvHca6EJsvqAd82gc6VMGule4HwebwMlwkpXuVqrNRj6CkCV2sKxgi9MyAUnZVnZ6lJ1/vKhHQ==",
+ "requires": {
+ "@babel/types": "^7.8.3"
+ }
+ },
+ "@babel/helper-replace-supers": {
+ "version": "7.8.6",
+ "resolved": "https://registry.npmjs.org/@babel/helper-replace-supers/-/helper-replace-supers-7.8.6.tgz",
+ "integrity": "sha512-PeMArdA4Sv/Wf4zXwBKPqVj7n9UF/xg6slNRtZW84FM7JpE1CbG8B612FyM4cxrf4fMAMGO0kR7voy1ForHHFA==",
+ "requires": {
+ "@babel/helper-member-expression-to-functions": "^7.8.3",
+ "@babel/helper-optimise-call-expression": "^7.8.3",
+ "@babel/traverse": "^7.8.6",
+ "@babel/types": "^7.8.6"
+ }
+ },
+ "@babel/helper-simple-access": {
+ "version": "7.8.3",
+ "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.8.3.tgz",
+ "integrity": "sha512-VNGUDjx5cCWg4vvCTR8qQ7YJYZ+HBjxOgXEl7ounz+4Sn7+LMD3CFrCTEU6/qXKbA2nKg21CwhhBzO0RpRbdCw==",
+ "requires": {
+ "@babel/template": "^7.8.3",
+ "@babel/types": "^7.8.3"
+ }
+ },
+ "@babel/helper-split-export-declaration": {
+ "version": "7.8.3",
+ "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.8.3.tgz",
+ "integrity": "sha512-3x3yOeyBhW851hroze7ElzdkeRXQYQbFIb7gLK1WQYsw2GWDay5gAJNw1sWJ0VFP6z5J1whqeXH/WCdCjZv6dA==",
+ "requires": {
+ "@babel/types": "^7.8.3"
+ }
+ },
+ "@babel/helper-validator-identifier": {
+ "version": "7.9.0",
+ "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.9.0.tgz",
+ "integrity": "sha512-6G8bQKjOh+of4PV/ThDm/rRqlU7+IGoJuofpagU5GlEl29Vv0RGqqt86ZGRV8ZuSOY3o+8yXl5y782SMcG7SHw=="
+ },
+ "@babel/helpers": {
+ "version": "7.9.2",
+ "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.9.2.tgz",
+ "integrity": "sha512-JwLvzlXVPjO8eU9c/wF9/zOIN7X6h8DYf7mG4CiFRZRvZNKEF5dQ3H3V+ASkHoIB3mWhatgl5ONhyqHRI6MppA==",
+ "requires": {
+ "@babel/template": "^7.8.3",
+ "@babel/traverse": "^7.9.0",
+ "@babel/types": "^7.9.0"
+ }
+ },
+ "@babel/highlight": {
+ "version": "7.9.0",
+ "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.9.0.tgz",
+ "integrity": "sha512-lJZPilxX7Op3Nv/2cvFdnlepPXDxi29wxteT57Q965oc5R9v86ztx0jfxVrTcBk8C2kcPkkDa2Z4T3ZsPPVWsQ==",
+ "requires": {
+ "@babel/helper-validator-identifier": "^7.9.0",
+ "chalk": "^2.0.0",
+ "js-tokens": "^4.0.0"
+ },
+ "dependencies": {
+ "ansi-styles": {
+ "version": "3.2.1",
+ "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz",
+ "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==",
+ "requires": {
+ "color-convert": "^1.9.0"
+ }
+ },
+ "chalk": {
+ "version": "2.4.2",
+ "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz",
+ "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==",
+ "requires": {
+ "ansi-styles": "^3.2.1",
+ "escape-string-regexp": "^1.0.5",
+ "supports-color": "^5.3.0"
+ }
+ },
+ "color-convert": {
+ "version": "1.9.3",
+ "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz",
+ "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==",
+ "requires": {
+ "color-name": "1.1.3"
+ }
+ },
+ "color-name": {
+ "version": "1.1.3",
+ "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz",
+ "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU="
+ },
+ "has-flag": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz",
+ "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0="
+ },
+ "supports-color": {
+ "version": "5.5.0",
+ "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz",
+ "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==",
+ "requires": {
+ "has-flag": "^3.0.0"
+ }
+ }
+ }
+ },
+ "@babel/parser": {
+ "version": "7.9.4",
+ "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.9.4.tgz",
+ "integrity": "sha512-bC49otXX6N0/VYhgOMh4gnP26E9xnDZK3TmbNpxYzzz9BQLBosQwfyOe9/cXUU3txYhTzLCbcqd5c8y/OmCjHA=="
+ },
+ "@babel/template": {
+ "version": "7.8.6",
+ "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.8.6.tgz",
+ "integrity": "sha512-zbMsPMy/v0PWFZEhQJ66bqjhH+z0JgMoBWuikXybgG3Gkd/3t5oQ1Rw2WQhnSrsOmsKXnZOx15tkC4qON/+JPg==",
+ "requires": {
+ "@babel/code-frame": "^7.8.3",
+ "@babel/parser": "^7.8.6",
+ "@babel/types": "^7.8.6"
+ }
+ },
+ "@babel/traverse": {
+ "version": "7.9.5",
+ "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.9.5.tgz",
+ "integrity": "sha512-c4gH3jsvSuGUezlP6rzSJ6jf8fYjLj3hsMZRx/nX0h+fmHN0w+ekubRrHPqnMec0meycA2nwCsJ7dC8IPem2FQ==",
+ "requires": {
+ "@babel/code-frame": "^7.8.3",
+ "@babel/generator": "^7.9.5",
+ "@babel/helper-function-name": "^7.9.5",
+ "@babel/helper-split-export-declaration": "^7.8.3",
+ "@babel/parser": "^7.9.0",
+ "@babel/types": "^7.9.5",
+ "debug": "^4.1.0",
+ "globals": "^11.1.0",
+ "lodash": "^4.17.13"
+ }
+ },
+ "@babel/types": {
+ "version": "7.9.5",
+ "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.9.5.tgz",
+ "integrity": "sha512-XjnvNqenk818r5zMaba+sLQjnbda31UfUURv3ei0qPQw4u+j2jMyJ5b11y8ZHYTRSI3NnInQkkkRT4fLqqPdHg==",
+ "requires": {
+ "@babel/helper-validator-identifier": "^7.9.5",
+ "lodash": "^4.17.13",
+ "to-fast-properties": "^2.0.0"
+ },
+ "dependencies": {
+ "@babel/helper-validator-identifier": {
+ "version": "7.9.5",
+ "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.9.5.tgz",
+ "integrity": "sha512-/8arLKUFq882w4tWGj9JYzRpAlZgiWUJ+dtteNTDqrRBz9Iguck9Rn3ykuBDoUwh2TO4tSAJlrxDUOXWklJe4g=="
+ }
+ }
+ },
+ "@discordjs/collection": {
+ "version": "0.1.5",
+ "resolved": "https://registry.npmjs.org/@discordjs/collection/-/collection-0.1.5.tgz",
+ "integrity": "sha512-CU1q0UXQUpFNzNB7gufgoisDHP7n+T3tkqTsp3MNUkVJ5+hS3BCvME8uCXAUFlz+6T2FbTCu75A+yQ7HMKqRKw=="
+ },
+ "@discordjs/form-data": {
+ "version": "3.0.1",
+ "resolved": "https://registry.npmjs.org/@discordjs/form-data/-/form-data-3.0.1.tgz",
+ "integrity": "sha512-ZfFsbgEXW71Rw/6EtBdrP5VxBJy4dthyC0tpQKGKmYFImlmmrykO14Za+BiIVduwjte0jXEBlhSKf0MWbFp9Eg==",
+ "requires": {
+ "asynckit": "^0.4.0",
+ "combined-stream": "^1.0.8",
+ "mime-types": "^2.1.12"
+ }
+ },
+ "@discordjs/opus": {
+ "version": "0.1.0",
+ "resolved": "https://registry.npmjs.org/@discordjs/opus/-/opus-0.1.0.tgz",
+ "integrity": "sha512-VWsrsgqSktxOEHx9SFcnOWJhYQOsyzaW3JVN73LDSzKrycEjtRIS+axlm4qeMGx60u6RH1SY15b3pl5G4+Y+gA==",
+ "requires": {
+ "node-addon-api": "^2.0.0",
+ "node-pre-gyp": "^0.14.0"
+ }
+ },
+ "@istanbuljs/load-nyc-config": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/@istanbuljs/load-nyc-config/-/load-nyc-config-1.0.0.tgz",
+ "integrity": "sha512-ZR0rq/f/E4f4XcgnDvtMWXCUJpi8eO0rssVhmztsZqLIEFA9UUP9zmpE0VxlM+kv/E1ul2I876Fwil2ayptDVg==",
+ "requires": {
+ "camelcase": "^5.3.1",
+ "find-up": "^4.1.0",
+ "js-yaml": "^3.13.1",
+ "resolve-from": "^5.0.0"
+ },
+ "dependencies": {
+ "resolve-from": {
+ "version": "5.0.0",
+ "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz",
+ "integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw=="
+ }
+ }
+ },
+ "@istanbuljs/schema": {
+ "version": "0.1.2",
+ "resolved": "https://registry.npmjs.org/@istanbuljs/schema/-/schema-0.1.2.tgz",
+ "integrity": "sha512-tsAQNx32a8CoFhjhijUIhI4kccIAgmGhy8LZMZgGfmXcpMbPRUqn5LWmgRttILi6yeGmBJd2xsPkFMs0PzgPCw=="
+ },
+ "@sentry/apm": {
+ "version": "5.15.4",
+ "resolved": "https://registry.npmjs.org/@sentry/apm/-/apm-5.15.4.tgz",
+ "integrity": "sha512-gcW225Jls1ShyBXMWN6zZyuVJwBOIQ63sI+URI2NSFsdpBpdpZ8yennIm+oMlSfb25Nzt9SId7TRSjPhlSbTZQ==",
+ "requires": {
+ "@sentry/browser": "5.15.4",
+ "@sentry/hub": "5.15.4",
+ "@sentry/minimal": "5.15.4",
+ "@sentry/types": "5.15.4",
+ "@sentry/utils": "5.15.4",
+ "tslib": "^1.9.3"
+ }
+ },
+ "@sentry/browser": {
+ "version": "5.15.4",
+ "resolved": "https://registry.npmjs.org/@sentry/browser/-/browser-5.15.4.tgz",
+ "integrity": "sha512-l/auT1HtZM3KxjCGQHYO/K51ygnlcuOrM+7Ga8gUUbU9ZXDYw6jRi0+Af9aqXKmdDw1naNxr7OCSy6NBrLWVZw==",
+ "requires": {
+ "@sentry/core": "5.15.4",
+ "@sentry/types": "5.15.4",
+ "@sentry/utils": "5.15.4",
+ "tslib": "^1.9.3"
+ }
+ },
+ "@sentry/core": {
+ "version": "5.15.4",
+ "resolved": "https://registry.npmjs.org/@sentry/core/-/core-5.15.4.tgz",
+ "integrity": "sha512-9KP4NM4SqfV5NixpvAymC7Nvp36Zj4dU2fowmxiq7OIbzTxGXDhwuN/t0Uh8xiqlkpkQqSECZ1OjSFXrBldetQ==",
+ "requires": {
+ "@sentry/hub": "5.15.4",
+ "@sentry/minimal": "5.15.4",
+ "@sentry/types": "5.15.4",
+ "@sentry/utils": "5.15.4",
+ "tslib": "^1.9.3"
+ }
+ },
+ "@sentry/hub": {
+ "version": "5.15.4",
+ "resolved": "https://registry.npmjs.org/@sentry/hub/-/hub-5.15.4.tgz",
+ "integrity": "sha512-1XJ1SVqadkbUT4zLS0TVIVl99si7oHizLmghR8LMFl5wOkGEgehHSoOydQkIAX2C7sJmaF5TZ47ORBHgkqclUg==",
+ "requires": {
+ "@sentry/types": "5.15.4",
+ "@sentry/utils": "5.15.4",
+ "tslib": "^1.9.3"
+ }
+ },
+ "@sentry/minimal": {
+ "version": "5.15.4",
+ "resolved": "https://registry.npmjs.org/@sentry/minimal/-/minimal-5.15.4.tgz",
+ "integrity": "sha512-GL4GZ3drS9ge+wmxkHBAMEwulaE7DMvAEfKQPDAjg2p3MfcCMhAYfuY4jJByAC9rg9OwBGGehz7UmhWMFjE0tw==",
+ "requires": {
+ "@sentry/hub": "5.15.4",
+ "@sentry/types": "5.15.4",
+ "tslib": "^1.9.3"
+ }
+ },
+ "@sentry/node": {
+ "version": "5.15.4",
+ "resolved": "https://registry.npmjs.org/@sentry/node/-/node-5.15.4.tgz",
+ "integrity": "sha512-OfdhNEvOJZ55ZkCUcVgctjaZkOw7rmLzO5VyDTSgevA4uLsPaTNXSAeK2GSQBXc5J0KdRpNz4sSIyuxOS4Z7Vg==",
+ "requires": {
+ "@sentry/apm": "5.15.4",
+ "@sentry/core": "5.15.4",
+ "@sentry/hub": "5.15.4",
+ "@sentry/types": "5.15.4",
+ "@sentry/utils": "5.15.4",
+ "cookie": "^0.3.1",
+ "https-proxy-agent": "^4.0.0",
+ "lru_map": "^0.3.3",
+ "tslib": "^1.9.3"
+ }
+ },
+ "@sentry/types": {
+ "version": "5.15.4",
+ "resolved": "https://registry.npmjs.org/@sentry/types/-/types-5.15.4.tgz",
+ "integrity": "sha512-quPHPpeAuwID48HLPmqBiyXE3xEiZLZ5D3CEbU3c3YuvvAg8qmfOOTI6z4Z3Eedi7flvYpnx3n7N3dXIEz30Eg=="
+ },
+ "@sentry/utils": {
+ "version": "5.15.4",
+ "resolved": "https://registry.npmjs.org/@sentry/utils/-/utils-5.15.4.tgz",
+ "integrity": "sha512-lO8SLBjrUDGADl0LOkd55R5oL510d/1SaI08/IBHZCxCUwI4TiYo5EPECq8mrj3XGfgCyq9osw33bymRlIDuSQ==",
+ "requires": {
+ "@sentry/types": "5.15.4",
+ "tslib": "^1.9.3"
+ }
+ },
+ "@types/color-name": {
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/@types/color-name/-/color-name-1.1.1.tgz",
+ "integrity": "sha512-rr+OQyAjxze7GgWrSaJwydHStIhHq2lvY3BOC2Mj7KnzI7XK0Uw1TOOdI9lDoajEbSWLiYgoo4f1R51erQfhPQ=="
+ },
+ "@types/node": {
+ "version": "13.11.1",
+ "resolved": "https://registry.npmjs.org/@types/node/-/node-13.11.1.tgz",
+ "integrity": "sha512-eWQGP3qtxwL8FGneRrC5DwrJLGN4/dH1clNTuLfN81HCrxVtxRjygDTUoZJ5ASlDEeo0ppYFQjQIlXhtXpOn6g=="
+ },
+ "abbrev": {
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz",
+ "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q=="
+ },
+ "abort-controller": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/abort-controller/-/abort-controller-3.0.0.tgz",
+ "integrity": "sha512-h8lQ8tacZYnR3vNQTgibj+tODHI5/+l06Au2Pcriv/Gmet0eaj4TwWH41sO9wnHDiQsEj19q0drzdWdeAHtweg==",
+ "requires": {
+ "event-target-shim": "^5.0.0"
+ }
+ },
+ "acorn": {
+ "version": "7.1.1",
+ "resolved": "https://registry.npmjs.org/acorn/-/acorn-7.1.1.tgz",
+ "integrity": "sha512-add7dgA5ppRPxCFJoAGfMDi7PIBXq1RtGo7BhbLaxwrXPOmw8gq48Y9ozT01hUKy9byMjlR20EJhu5zlkErEkg==",
+ "dev": true
+ },
+ "acorn-jsx": {
+ "version": "5.2.0",
+ "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.2.0.tgz",
+ "integrity": "sha512-HiUX/+K2YpkpJ+SzBffkM/AQ2YE03S0U1kjTLVpoJdhZMOWy8qvXVN9JdLqv2QsaQ6MPYQIuNmwD8zOiYUofLQ==",
+ "dev": true
+ },
+ "agent-base": {
+ "version": "5.1.1",
+ "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-5.1.1.tgz",
+ "integrity": "sha512-TMeqbNl2fMW0nMjTEPOwe3J/PRFP4vqeoNuQMG0HlMrtm5QxKqdvAkZ1pRBQ/ulIyDD5Yq0nJ7YbdD8ey0TO3g=="
+ },
+ "aggregate-error": {
+ "version": "3.0.1",
+ "resolved": "https://registry.npmjs.org/aggregate-error/-/aggregate-error-3.0.1.tgz",
+ "integrity": "sha512-quoaXsZ9/BLNae5yiNoUz+Nhkwz83GhWwtYFglcjEQB2NDHCIpApbqXxIFnm4Pq/Nvhrsq5sYJFyohrrxnTGAA==",
+ "requires": {
+ "clean-stack": "^2.0.0",
+ "indent-string": "^4.0.0"
+ }
+ },
+ "ansi-escapes": {
+ "version": "4.3.1",
+ "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.1.tgz",
+ "integrity": "sha512-JWF7ocqNrp8u9oqpgV+wH5ftbt+cfvv+PTjOvKLT3AdYly/LmORARfEVT1iyjwN+4MqE5UmVKoAdIBqeoCHgLA==",
+ "dev": true,
+ "requires": {
+ "type-fest": "^0.11.0"
+ },
+ "dependencies": {
+ "type-fest": {
+ "version": "0.11.0",
+ "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.11.0.tgz",
+ "integrity": "sha512-OdjXJxnCN1AvyLSzeKIgXTXxV+99ZuXl3Hpo9XpJAv9MBcHrrJOQ5kV7ypXOuQie+AmWG25hLbiKdwYTifzcfQ==",
+ "dev": true
+ }
+ }
+ },
+ "ansi-regex": {
+ "version": "5.0.0",
+ "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz",
+ "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg=="
+ },
+ "ansi-styles": {
+ "version": "4.2.1",
+ "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz",
+ "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==",
+ "requires": {
+ "@types/color-name": "^1.1.1",
+ "color-convert": "^2.0.1"
+ }
+ },
+ "append-transform": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/append-transform/-/append-transform-2.0.0.tgz",
+ "integrity": "sha512-7yeyCEurROLQJFv5Xj4lEGTy0borxepjFv1g22oAdqFu//SrAlDl1O1Nxx15SH1RoliUml6p8dwJW9jvZughhg==",
+ "requires": {
+ "default-require-extensions": "^3.0.0"
+ }
+ },
+ "aproba": {
+ "version": "1.2.0",
+ "resolved": "https://registry.npmjs.org/aproba/-/aproba-1.2.0.tgz",
+ "integrity": "sha512-Y9J6ZjXtoYh8RnXVCMOU/ttDmk1aBjunq9vO0ta5x85WDQiQfUF9sIPBITdbiiIVcBo03Hi3jMxigBtsddlXRw=="
+ },
+ "archy": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/archy/-/archy-1.0.0.tgz",
+ "integrity": "sha1-+cjBN1fMHde8N5rHeyxipcKGjEA="
+ },
+ "are-we-there-yet": {
+ "version": "1.1.5",
+ "resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-1.1.5.tgz",
+ "integrity": "sha512-5hYdAkZlcG8tOLujVDTgCT+uPX0VnpAH28gWsLfzpXYm7wP6mp5Q/gYyR7YQ0cKVJcXJnl3j2kpBan13PtQf6w==",
+ "requires": {
+ "delegates": "^1.0.0",
+ "readable-stream": "^2.0.6"
+ }
+ },
+ "argparse": {
+ "version": "1.0.10",
+ "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz",
+ "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==",
+ "requires": {
+ "sprintf-js": "~1.0.2"
+ }
+ },
+ "array-includes": {
+ "version": "3.1.1",
+ "resolved": "https://registry.npmjs.org/array-includes/-/array-includes-3.1.1.tgz",
+ "integrity": "sha512-c2VXaCHl7zPsvpkFsw4nxvFie4fh1ur9bpcgsVkIjqn0H/Xwdg+7fv3n2r/isyS8EBj5b06M9kHyZuIr4El6WQ==",
+ "dev": true,
+ "requires": {
+ "define-properties": "^1.1.3",
+ "es-abstract": "^1.17.0",
+ "is-string": "^1.0.5"
+ }
+ },
+ "array.prototype.flat": {
+ "version": "1.2.3",
+ "resolved": "https://registry.npmjs.org/array.prototype.flat/-/array.prototype.flat-1.2.3.tgz",
+ "integrity": "sha512-gBlRZV0VSmfPIeWfuuy56XZMvbVfbEUnOXUvt3F/eUUUSyzlgLxhEX4YAEpxNAogRGehPSnfXyPtYyKAhkzQhQ==",
+ "dev": true,
+ "requires": {
+ "define-properties": "^1.1.3",
+ "es-abstract": "^1.17.0-next.1"
+ }
+ },
+ "astral-regex": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/astral-regex/-/astral-regex-1.0.0.tgz",
+ "integrity": "sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg==",
+ "dev": true
+ },
+ "asynckit": {
+ "version": "0.4.0",
+ "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz",
+ "integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k="
+ },
+ "balanced-match": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz",
+ "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c="
+ },
+ "bl": {
+ "version": "2.2.0",
+ "resolved": "https://registry.npmjs.org/bl/-/bl-2.2.0.tgz",
+ "integrity": "sha512-wbgvOpqopSr7uq6fJrLH8EsvYMJf9gzfo2jCsL2eTy75qXPukA4pCgHamOQkZtY5vmfVtjB+P3LNlMHW5CEZXA==",
+ "requires": {
+ "readable-stream": "^2.3.5",
+ "safe-buffer": "^5.1.1"
+ }
+ },
+ "bluebird": {
+ "version": "3.5.1",
+ "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.5.1.tgz",
+ "integrity": "sha512-MKiLiV+I1AA596t9w1sQJ8jkiSr5+ZKi0WKrYGUn6d1Fx+Ij4tIj+m2WMQSGczs5jZVxV339chE8iwk6F64wjA=="
+ },
+ "brace-expansion": {
+ "version": "1.1.11",
+ "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz",
+ "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==",
+ "requires": {
+ "balanced-match": "^1.0.0",
+ "concat-map": "0.0.1"
+ }
+ },
+ "bson": {
+ "version": "1.1.4",
+ "resolved": "https://registry.npmjs.org/bson/-/bson-1.1.4.tgz",
+ "integrity": "sha512-S/yKGU1syOMzO86+dGpg2qGoDL0zvzcb262G+gqEy6TgP6rt6z6qxSFX/8X6vLC91P7G7C3nLs0+bvDzmvBA3Q=="
+ },
+ "caching-transform": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/caching-transform/-/caching-transform-4.0.0.tgz",
+ "integrity": "sha512-kpqOvwXnjjN44D89K5ccQC+RUrsy7jB/XLlRrx0D7/2HNcTPqzsb6XgYoErwko6QsV184CA2YgS1fxDiiDZMWA==",
+ "requires": {
+ "hasha": "^5.0.0",
+ "make-dir": "^3.0.0",
+ "package-hash": "^4.0.0",
+ "write-file-atomic": "^3.0.0"
+ }
+ },
+ "callsites": {
+ "version": "3.1.0",
+ "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz",
+ "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==",
+ "dev": true
+ },
+ "camelcase": {
+ "version": "5.3.1",
+ "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz",
+ "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg=="
+ },
+ "chalk": {
+ "version": "2.4.2",
+ "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz",
+ "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==",
+ "dev": true,
+ "requires": {
+ "ansi-styles": "^3.2.1",
+ "escape-string-regexp": "^1.0.5",
+ "supports-color": "^5.3.0"
+ },
+ "dependencies": {
+ "ansi-styles": {
+ "version": "3.2.1",
+ "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz",
+ "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==",
+ "dev": true,
+ "requires": {
+ "color-convert": "^1.9.0"
+ }
+ },
+ "color-convert": {
+ "version": "1.9.3",
+ "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz",
+ "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==",
+ "dev": true,
+ "requires": {
+ "color-name": "1.1.3"
+ }
+ },
+ "color-name": {
+ "version": "1.1.3",
+ "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz",
+ "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=",
+ "dev": true
+ },
+ "has-flag": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz",
+ "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=",
+ "dev": true
+ },
+ "supports-color": {
+ "version": "5.5.0",
+ "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz",
+ "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==",
+ "dev": true,
+ "requires": {
+ "has-flag": "^3.0.0"
+ }
+ }
+ }
+ },
+ "chardet": {
+ "version": "0.7.0",
+ "resolved": "https://registry.npmjs.org/chardet/-/chardet-0.7.0.tgz",
+ "integrity": "sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA==",
+ "dev": true
+ },
+ "chownr": {
+ "version": "1.1.4",
+ "resolved": "https://registry.npmjs.org/chownr/-/chownr-1.1.4.tgz",
+ "integrity": "sha512-jJ0bqzaylmJtVnNgzTeSOs8DPavpbYgEr/b0YL8/2GO3xJEhInFmhKMUnEJQjZumK7KXGFhUy89PrsJWlakBVg=="
+ },
+ "clean-stack": {
+ "version": "2.2.0",
+ "resolved": "https://registry.npmjs.org/clean-stack/-/clean-stack-2.2.0.tgz",
+ "integrity": "sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A=="
+ },
+ "cli-cursor": {
+ "version": "3.1.0",
+ "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-3.1.0.tgz",
+ "integrity": "sha512-I/zHAwsKf9FqGoXM4WWRACob9+SNukZTd94DWF57E4toouRulbCxcUh6RKUEOQlYTHJnzkPMySvPNaaSLNfLZw==",
+ "dev": true,
+ "requires": {
+ "restore-cursor": "^3.1.0"
+ }
+ },
+ "cli-width": {
+ "version": "2.2.0",
+ "resolved": "https://registry.npmjs.org/cli-width/-/cli-width-2.2.0.tgz",
+ "integrity": "sha1-/xnt6Kml5XkyQUewwR8PvLq+1jk=",
+ "dev": true
+ },
+ "cliui": {
+ "version": "6.0.0",
+ "resolved": "https://registry.npmjs.org/cliui/-/cliui-6.0.0.tgz",
+ "integrity": "sha512-t6wbgtoCXvAzst7QgXxJYqPt0usEfbgQdftEPbLL/cvv6HPE5VgvqCuAIDR0NgU52ds6rFwqrgakNLrHEjCbrQ==",
+ "requires": {
+ "string-width": "^4.2.0",
+ "strip-ansi": "^6.0.0",
+ "wrap-ansi": "^6.2.0"
+ }
+ },
+ "code-point-at": {
+ "version": "1.1.0",
+ "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz",
+ "integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c="
+ },
+ "color-convert": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz",
+ "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==",
+ "requires": {
+ "color-name": "~1.1.4"
+ }
+ },
+ "color-name": {
+ "version": "1.1.4",
+ "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz",
+ "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA=="
+ },
+ "colors": {
+ "version": "1.4.0",
+ "resolved": "https://registry.npmjs.org/colors/-/colors-1.4.0.tgz",
+ "integrity": "sha512-a+UqTh4kgZg/SlGvfbzDHpgRu7AAQOmmqRHJnxhRZICKFUT91brVhNNt58CMWU9PsBbv3PDCZUHbVxuDiH2mtA=="
+ },
+ "combined-stream": {
+ "version": "1.0.8",
+ "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz",
+ "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==",
+ "requires": {
+ "delayed-stream": "~1.0.0"
+ }
+ },
+ "commondir": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz",
+ "integrity": "sha1-3dgA2gxmEnOTzKWVDqloo6rxJTs="
+ },
+ "concat-map": {
+ "version": "0.0.1",
+ "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz",
+ "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s="
+ },
+ "console-control-strings": {
+ "version": "1.1.0",
+ "resolved": "https://registry.npmjs.org/console-control-strings/-/console-control-strings-1.1.0.tgz",
+ "integrity": "sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4="
+ },
+ "contains-path": {
+ "version": "0.1.0",
+ "resolved": "https://registry.npmjs.org/contains-path/-/contains-path-0.1.0.tgz",
+ "integrity": "sha1-/ozxhP9mcLa67wGp1IYaXL7EEgo=",
+ "dev": true
+ },
+ "convert-source-map": {
+ "version": "1.7.0",
+ "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.7.0.tgz",
+ "integrity": "sha512-4FJkXzKXEDB1snCFZlLP4gpC3JILicCpGbzG9f9G7tGqGCzETQ2hWPrcinA9oU4wtf2biUaEH5065UnMeR33oA==",
+ "requires": {
+ "safe-buffer": "~5.1.1"
+ }
+ },
+ "cookie": {
+ "version": "0.3.1",
+ "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.3.1.tgz",
+ "integrity": "sha1-5+Ch+e9DtMi6klxcWpboBtFoc7s="
+ },
+ "core-util-is": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz",
+ "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac="
+ },
+ "cross-spawn": {
+ "version": "7.0.2",
+ "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.2.tgz",
+ "integrity": "sha512-PD6G8QG3S4FK/XCGFbEQrDqO2AnMMsy0meR7lerlIOHAAbkuavGU/pOqprrlvfTNjvowivTeBsjebAL0NSoMxw==",
+ "requires": {
+ "path-key": "^3.1.0",
+ "shebang-command": "^2.0.0",
+ "which": "^2.0.1"
+ }
+ },
+ "dateformat": {
+ "version": "3.0.3",
+ "resolved": "https://registry.npmjs.org/dateformat/-/dateformat-3.0.3.tgz",
+ "integrity": "sha512-jyCETtSl3VMZMWeRo7iY1FL19ges1t55hMo5yaam4Jrsm5EPL89UQkoQRyiI+Yf4k8r2ZpdngkV8hr1lIdjb3Q=="
+ },
+ "debug": {
+ "version": "4.1.1",
+ "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz",
+ "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==",
+ "requires": {
+ "ms": "^2.1.1"
+ }
+ },
+ "decamelize": {
+ "version": "1.2.0",
+ "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz",
+ "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA="
+ },
+ "deep-extend": {
+ "version": "0.6.0",
+ "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz",
+ "integrity": "sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA=="
+ },
+ "deep-is": {
+ "version": "0.1.3",
+ "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.3.tgz",
+ "integrity": "sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ=",
+ "dev": true
+ },
+ "default-require-extensions": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/default-require-extensions/-/default-require-extensions-3.0.0.tgz",
+ "integrity": "sha512-ek6DpXq/SCpvjhpFsLFRVtIxJCRw6fUR42lYMVZuUMK7n8eMz4Uh5clckdBjEpLhn/gEBZo7hDJnJcwdKLKQjg==",
+ "requires": {
+ "strip-bom": "^4.0.0"
+ }
+ },
+ "define-properties": {
+ "version": "1.1.3",
+ "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz",
+ "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==",
+ "dev": true,
+ "requires": {
+ "object-keys": "^1.0.12"
+ }
+ },
+ "delayed-stream": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz",
+ "integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk="
+ },
+ "delegates": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/delegates/-/delegates-1.0.0.tgz",
+ "integrity": "sha1-hMbhWbgZBP3KWaDvRM2HDTElD5o="
+ },
+ "denque": {
+ "version": "1.4.1",
+ "resolved": "https://registry.npmjs.org/denque/-/denque-1.4.1.tgz",
+ "integrity": "sha512-OfzPuSZKGcgr96rf1oODnfjqBFmr1DVoc/TrItj3Ohe0Ah1C5WX5Baquw/9U9KovnQ88EqmJbD66rKYUQYN1tQ=="
+ },
+ "detect-libc": {
+ "version": "1.0.3",
+ "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-1.0.3.tgz",
+ "integrity": "sha1-+hN8S9aY7fVc1c0CrFWfkaTEups="
+ },
+ "discord.js": {
+ "version": "12.2.0",
+ "resolved": "https://registry.npmjs.org/discord.js/-/discord.js-12.2.0.tgz",
+ "integrity": "sha512-Ueb/0SOsxXyqwvwFYFe0msMrGqH1OMqpp2Dpbplnlr4MzcRrFWwsBM9gKNZXPVBHWUKiQkwU8AihXBXIvTTSvg==",
+ "requires": {
+ "@discordjs/collection": "^0.1.5",
+ "@discordjs/form-data": "^3.0.1",
+ "abort-controller": "^3.0.0",
+ "node-fetch": "^2.6.0",
+ "prism-media": "^1.2.0",
+ "setimmediate": "^1.0.5",
+ "tweetnacl": "^1.0.3",
+ "ws": "^7.2.1"
+ }
+ },
+ "doctrine": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz",
+ "integrity": "sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==",
+ "dev": true,
+ "requires": {
+ "esutils": "^2.0.2"
+ }
+ },
+ "emoji-regex": {
+ "version": "8.0.0",
+ "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz",
+ "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A=="
+ },
+ "error-ex": {
+ "version": "1.3.2",
+ "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz",
+ "integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==",
+ "dev": true,
+ "requires": {
+ "is-arrayish": "^0.2.1"
+ }
+ },
+ "es-abstract": {
+ "version": "1.17.5",
+ "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.17.5.tgz",
+ "integrity": "sha512-BR9auzDbySxOcfog0tLECW8l28eRGpDpU3Dm3Hp4q/N+VtLTmyj4EUN088XZWQDW/hzj6sYRDXeOFsaAODKvpg==",
+ "dev": true,
+ "requires": {
+ "es-to-primitive": "^1.2.1",
+ "function-bind": "^1.1.1",
+ "has": "^1.0.3",
+ "has-symbols": "^1.0.1",
+ "is-callable": "^1.1.5",
+ "is-regex": "^1.0.5",
+ "object-inspect": "^1.7.0",
+ "object-keys": "^1.1.1",
+ "object.assign": "^4.1.0",
+ "string.prototype.trimleft": "^2.1.1",
+ "string.prototype.trimright": "^2.1.1"
+ }
+ },
+ "es-to-primitive": {
+ "version": "1.2.1",
+ "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz",
+ "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==",
+ "dev": true,
+ "requires": {
+ "is-callable": "^1.1.4",
+ "is-date-object": "^1.0.1",
+ "is-symbol": "^1.0.2"
+ }
+ },
+ "es6-error": {
+ "version": "4.1.1",
+ "resolved": "https://registry.npmjs.org/es6-error/-/es6-error-4.1.1.tgz",
+ "integrity": "sha512-Um/+FxMr9CISWh0bi5Zv0iOD+4cFh5qLeks1qhAopKVAJw3drgKbKySikp7wGhDL0HPeaja0P5ULZrxLkniUVg=="
+ },
+ "escape-string-regexp": {
+ "version": "1.0.5",
+ "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz",
+ "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ="
+ },
+ "eslint": {
+ "version": "6.8.0",
+ "resolved": "https://registry.npmjs.org/eslint/-/eslint-6.8.0.tgz",
+ "integrity": "sha512-K+Iayyo2LtyYhDSYwz5D5QdWw0hCacNzyq1Y821Xna2xSJj7cijoLLYmLxTQgcgZ9mC61nryMy9S7GRbYpI5Ig==",
+ "dev": true,
+ "requires": {
+ "@babel/code-frame": "^7.0.0",
+ "ajv": "^6.10.0",
+ "chalk": "^2.1.0",
+ "cross-spawn": "^6.0.5",
+ "debug": "^4.0.1",
+ "doctrine": "^3.0.0",
+ "eslint-scope": "^5.0.0",
+ "eslint-utils": "^1.4.3",
+ "eslint-visitor-keys": "^1.1.0",
+ "espree": "^6.1.2",
+ "esquery": "^1.0.1",
+ "esutils": "^2.0.2",
+ "file-entry-cache": "^5.0.1",
+ "functional-red-black-tree": "^1.0.1",
+ "glob-parent": "^5.0.0",
+ "globals": "^12.1.0",
+ "ignore": "^4.0.6",
+ "import-fresh": "^3.0.0",
+ "imurmurhash": "^0.1.4",
+ "inquirer": "^7.0.0",
+ "is-glob": "^4.0.0",
+ "js-yaml": "^3.13.1",
+ "json-stable-stringify-without-jsonify": "^1.0.1",
+ "levn": "^0.3.0",
+ "lodash": "^4.17.14",
+ "minimatch": "^3.0.4",
+ "mkdirp": "^0.5.1",
+ "natural-compare": "^1.4.0",
+ "optionator": "^0.8.3",
+ "progress": "^2.0.0",
+ "regexpp": "^2.0.1",
+ "semver": "^6.1.2",
+ "strip-ansi": "^5.2.0",
+ "strip-json-comments": "^3.0.1",
+ "table": "^5.2.3",
+ "text-table": "^0.2.0",
+ "v8-compile-cache": "^2.0.3"
+ },
+ "dependencies": {
+ "ajv": {
+ "version": "6.12.0",
+ "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.0.tgz",
+ "integrity": "sha512-D6gFiFA0RRLyUbvijN74DWAjXSFxWKaWP7mldxkVhyhAV3+SWA9HEJPHQ2c9soIeTFJqcSdFDGFgdqs1iUU2Hw==",
+ "dev": true,
+ "requires": {
+ "fast-deep-equal": "^3.1.1",
+ "fast-json-stable-stringify": "^2.0.0",
+ "json-schema-traverse": "^0.4.1",
+ "uri-js": "^4.2.2"
+ }
+ },
+ "ansi-regex": {
+ "version": "4.1.0",
+ "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz",
+ "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==",
+ "dev": true
+ },
+ "cross-spawn": {
+ "version": "6.0.5",
+ "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz",
+ "integrity": "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==",
+ "dev": true,
+ "requires": {
+ "nice-try": "^1.0.4",
+ "path-key": "^2.0.1",
+ "semver": "^5.5.0",
+ "shebang-command": "^1.2.0",
+ "which": "^1.2.9"
+ },
+ "dependencies": {
+ "semver": {
+ "version": "5.7.1",
+ "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz",
+ "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==",
+ "dev": true
+ }
+ }
+ },
+ "globals": {
+ "version": "12.4.0",
+ "resolved": "https://registry.npmjs.org/globals/-/globals-12.4.0.tgz",
+ "integrity": "sha512-BWICuzzDvDoH54NHKCseDanAhE3CeDorgDL5MT6LMXXj2WCnd9UC2szdk4AWLfjdgNBCXLUanXYcpBBKOSWGwg==",
+ "dev": true,
+ "requires": {
+ "type-fest": "^0.8.1"
+ }
+ },
+ "path-key": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz",
+ "integrity": "sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A=",
+ "dev": true
+ },
+ "shebang-command": {
+ "version": "1.2.0",
+ "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz",
+ "integrity": "sha1-RKrGW2lbAzmJaMOfNj/uXer98eo=",
+ "dev": true,
+ "requires": {
+ "shebang-regex": "^1.0.0"
+ }
+ },
+ "shebang-regex": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz",
+ "integrity": "sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM=",
+ "dev": true
+ },
+ "strip-ansi": {
+ "version": "5.2.0",
+ "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz",
+ "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==",
+ "dev": true,
+ "requires": {
+ "ansi-regex": "^4.1.0"
+ }
+ },
+ "which": {
+ "version": "1.3.1",
+ "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz",
+ "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==",
+ "dev": true,
+ "requires": {
+ "isexe": "^2.0.0"
+ }
+ }
+ }
+ },
+ "eslint-config-standard": {
+ "version": "14.1.1",
+ "resolved": "https://registry.npmjs.org/eslint-config-standard/-/eslint-config-standard-14.1.1.tgz",
+ "integrity": "sha512-Z9B+VR+JIXRxz21udPTL9HpFMyoMUEeX1G251EQ6e05WD9aPVtVBn09XUmZ259wCMlCDmYDSZG62Hhm+ZTJcUg==",
+ "dev": true
+ },
+ "eslint-import-resolver-node": {
+ "version": "0.3.3",
+ "resolved": "https://registry.npmjs.org/eslint-import-resolver-node/-/eslint-import-resolver-node-0.3.3.tgz",
+ "integrity": "sha512-b8crLDo0M5RSe5YG8Pu2DYBj71tSB6OvXkfzwbJU2w7y8P4/yo0MyF8jU26IEuEuHF2K5/gcAJE3LhQGqBBbVg==",
+ "dev": true,
+ "requires": {
+ "debug": "^2.6.9",
+ "resolve": "^1.13.1"
+ },
+ "dependencies": {
+ "debug": {
+ "version": "2.6.9",
+ "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz",
+ "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==",
+ "dev": true,
+ "requires": {
+ "ms": "2.0.0"
+ }
+ },
+ "ms": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz",
+ "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=",
+ "dev": true
+ }
+ }
+ },
+ "eslint-module-utils": {
+ "version": "2.6.0",
+ "resolved": "https://registry.npmjs.org/eslint-module-utils/-/eslint-module-utils-2.6.0.tgz",
+ "integrity": "sha512-6j9xxegbqe8/kZY8cYpcp0xhbK0EgJlg3g9mib3/miLaExuuwc3n5UEfSnU6hWMbT0FAYVvDbL9RrRgpUeQIvA==",
+ "dev": true,
+ "requires": {
+ "debug": "^2.6.9",
+ "pkg-dir": "^2.0.0"
+ },
+ "dependencies": {
+ "debug": {
+ "version": "2.6.9",
+ "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz",
+ "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==",
+ "dev": true,
+ "requires": {
+ "ms": "2.0.0"
+ }
+ },
+ "find-up": {
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/find-up/-/find-up-2.1.0.tgz",
+ "integrity": "sha1-RdG35QbHF93UgndaK3eSCjwMV6c=",
+ "dev": true,
+ "requires": {
+ "locate-path": "^2.0.0"
+ }
+ },
+ "locate-path": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-2.0.0.tgz",
+ "integrity": "sha1-K1aLJl7slExtnA3pw9u7ygNUzY4=",
+ "dev": true,
+ "requires": {
+ "p-locate": "^2.0.0",
+ "path-exists": "^3.0.0"
+ }
+ },
+ "ms": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz",
+ "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=",
+ "dev": true
+ },
+ "p-limit": {
+ "version": "1.3.0",
+ "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-1.3.0.tgz",
+ "integrity": "sha512-vvcXsLAJ9Dr5rQOPk7toZQZJApBl2K4J6dANSsEuh6QI41JYcsS/qhTGa9ErIUUgK3WNQoJYvylxvjqmiqEA9Q==",
+ "dev": true,
+ "requires": {
+ "p-try": "^1.0.0"
+ }
+ },
+ "p-locate": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-2.0.0.tgz",
+ "integrity": "sha1-IKAQOyIqcMj9OcwuWAaA893l7EM=",
+ "dev": true,
+ "requires": {
+ "p-limit": "^1.1.0"
+ }
+ },
+ "p-try": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/p-try/-/p-try-1.0.0.tgz",
+ "integrity": "sha1-y8ec26+P1CKOE/Yh8rGiN8GyB7M=",
+ "dev": true
+ },
+ "path-exists": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz",
+ "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=",
+ "dev": true
+ },
+ "pkg-dir": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-2.0.0.tgz",
+ "integrity": "sha1-9tXREJ4Z1j7fQo4L1X4Sd3YVM0s=",
+ "dev": true,
+ "requires": {
+ "find-up": "^2.1.0"
+ }
+ }
+ }
+ },
+ "eslint-plugin-es": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/eslint-plugin-es/-/eslint-plugin-es-3.0.0.tgz",
+ "integrity": "sha512-6/Jb/J/ZvSebydwbBJO1R9E5ky7YeElfK56Veh7e4QGFHCXoIXGH9HhVz+ibJLM3XJ1XjP+T7rKBLUa/Y7eIng==",
+ "dev": true,
+ "requires": {
+ "eslint-utils": "^2.0.0",
+ "regexpp": "^3.0.0"
+ },
+ "dependencies": {
+ "eslint-utils": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/eslint-utils/-/eslint-utils-2.0.0.tgz",
+ "integrity": "sha512-0HCPuJv+7Wv1bACm8y5/ECVfYdfsAm9xmVb7saeFlxjPYALefjhbYoCkBjPdPzGH8wWyTpAez82Fh3VKYEZ8OA==",
+ "dev": true,
+ "requires": {
+ "eslint-visitor-keys": "^1.1.0"
+ }
+ },
+ "regexpp": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/regexpp/-/regexpp-3.0.0.tgz",
+ "integrity": "sha512-Z+hNr7RAVWxznLPuA7DIh8UNX1j9CDrUQxskw9IrBE1Dxue2lyXT+shqEIeLUjrokxIP8CMy1WkjgG3rTsd5/g==",
+ "dev": true
+ }
+ }
+ },
+ "eslint-plugin-import": {
+ "version": "2.20.2",
+ "resolved": "https://registry.npmjs.org/eslint-plugin-import/-/eslint-plugin-import-2.20.2.tgz",
+ "integrity": "sha512-FObidqpXrR8OnCh4iNsxy+WACztJLXAHBO5hK79T1Hc77PgQZkyDGA5Ag9xAvRpglvLNxhH/zSmZ70/pZ31dHg==",
+ "dev": true,
+ "requires": {
+ "array-includes": "^3.0.3",
+ "array.prototype.flat": "^1.2.1",
+ "contains-path": "^0.1.0",
+ "debug": "^2.6.9",
+ "doctrine": "1.5.0",
+ "eslint-import-resolver-node": "^0.3.2",
+ "eslint-module-utils": "^2.4.1",
+ "has": "^1.0.3",
+ "minimatch": "^3.0.4",
+ "object.values": "^1.1.0",
+ "read-pkg-up": "^2.0.0",
+ "resolve": "^1.12.0"
+ },
+ "dependencies": {
+ "debug": {
+ "version": "2.6.9",
+ "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz",
+ "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==",
+ "dev": true,
+ "requires": {
+ "ms": "2.0.0"
+ }
+ },
+ "doctrine": {
+ "version": "1.5.0",
+ "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-1.5.0.tgz",
+ "integrity": "sha1-N53Ocw9hZvds76TmcHoVmwLFpvo=",
+ "dev": true,
+ "requires": {
+ "esutils": "^2.0.2",
+ "isarray": "^1.0.0"
+ }
+ },
+ "ms": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz",
+ "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=",
+ "dev": true
+ }
+ }
+ },
+ "eslint-plugin-node": {
+ "version": "11.1.0",
+ "resolved": "https://registry.npmjs.org/eslint-plugin-node/-/eslint-plugin-node-11.1.0.tgz",
+ "integrity": "sha512-oUwtPJ1W0SKD0Tr+wqu92c5xuCeQqB3hSCHasn/ZgjFdA9iDGNkNf2Zi9ztY7X+hNuMib23LNGRm6+uN+KLE3g==",
+ "dev": true,
+ "requires": {
+ "eslint-plugin-es": "^3.0.0",
+ "eslint-utils": "^2.0.0",
+ "ignore": "^5.1.1",
+ "minimatch": "^3.0.4",
+ "resolve": "^1.10.1",
+ "semver": "^6.1.0"
+ },
+ "dependencies": {
+ "eslint-utils": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/eslint-utils/-/eslint-utils-2.0.0.tgz",
+ "integrity": "sha512-0HCPuJv+7Wv1bACm8y5/ECVfYdfsAm9xmVb7saeFlxjPYALefjhbYoCkBjPdPzGH8wWyTpAez82Fh3VKYEZ8OA==",
+ "dev": true,
+ "requires": {
+ "eslint-visitor-keys": "^1.1.0"
+ }
+ },
+ "ignore": {
+ "version": "5.1.4",
+ "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.1.4.tgz",
+ "integrity": "sha512-MzbUSahkTW1u7JpKKjY7LCARd1fU5W2rLdxlM4kdkayuCwZImjkpluF9CM1aLewYJguPDqewLam18Y6AU69A8A==",
+ "dev": true
+ }
+ }
+ },
+ "eslint-plugin-promise": {
+ "version": "4.2.1",
+ "resolved": "https://registry.npmjs.org/eslint-plugin-promise/-/eslint-plugin-promise-4.2.1.tgz",
+ "integrity": "sha512-VoM09vT7bfA7D+upt+FjeBO5eHIJQBUWki1aPvB+vbNiHS3+oGIJGIeyBtKQTME6UPXXy3vV07OL1tHd3ANuDw==",
+ "dev": true
+ },
+ "eslint-plugin-standard": {
+ "version": "4.0.1",
+ "resolved": "https://registry.npmjs.org/eslint-plugin-standard/-/eslint-plugin-standard-4.0.1.tgz",
+ "integrity": "sha512-v/KBnfyaOMPmZc/dmc6ozOdWqekGp7bBGq4jLAecEfPGmfKiWS4sA8sC0LqiV9w5qmXAtXVn4M3p1jSyhY85SQ==",
+ "dev": true
+ },
+ "eslint-scope": {
+ "version": "5.0.0",
+ "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-5.0.0.tgz",
+ "integrity": "sha512-oYrhJW7S0bxAFDvWqzvMPRm6pcgcnWc4QnofCAqRTRfQC0JcwenzGglTtsLyIuuWFfkqDG9vz67cnttSd53djw==",
+ "dev": true,
+ "requires": {
+ "esrecurse": "^4.1.0",
+ "estraverse": "^4.1.1"
+ }
+ },
+ "eslint-utils": {
+ "version": "1.4.3",
+ "resolved": "https://registry.npmjs.org/eslint-utils/-/eslint-utils-1.4.3.tgz",
+ "integrity": "sha512-fbBN5W2xdY45KulGXmLHZ3c3FHfVYmKg0IrAKGOkT/464PQsx2UeIzfz1RmEci+KLm1bBaAzZAh8+/E+XAeZ8Q==",
+ "dev": true,
+ "requires": {
+ "eslint-visitor-keys": "^1.1.0"
+ }
+ },
+ "eslint-visitor-keys": {
+ "version": "1.1.0",
+ "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-1.1.0.tgz",
+ "integrity": "sha512-8y9YjtM1JBJU/A9Kc+SbaOV4y29sSWckBwMHa+FGtVj5gN/sbnKDf6xJUl+8g7FAij9LVaP8C24DUiH/f/2Z9A==",
+ "dev": true
+ },
+ "espree": {
+ "version": "6.2.1",
+ "resolved": "https://registry.npmjs.org/espree/-/espree-6.2.1.tgz",
+ "integrity": "sha512-ysCxRQY3WaXJz9tdbWOwuWr5Y/XrPTGX9Kiz3yoUXwW0VZ4w30HTkQLaGx/+ttFjF8i+ACbArnB4ce68a9m5hw==",
+ "dev": true,
+ "requires": {
+ "acorn": "^7.1.1",
+ "acorn-jsx": "^5.2.0",
+ "eslint-visitor-keys": "^1.1.0"
+ }
+ },
+ "esprima": {
+ "version": "4.0.1",
+ "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz",
+ "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A=="
+ },
+ "esquery": {
+ "version": "1.2.0",
+ "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.2.0.tgz",
+ "integrity": "sha512-weltsSqdeWIX9G2qQZz7KlTRJdkkOCTPgLYJUz1Hacf48R4YOwGPHO3+ORfWedqJKbq5WQmsgK90n+pFLIKt/Q==",
+ "dev": true,
+ "requires": {
+ "estraverse": "^5.0.0"
+ },
+ "dependencies": {
+ "estraverse": {
+ "version": "5.0.0",
+ "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.0.0.tgz",
+ "integrity": "sha512-j3acdrMzqrxmJTNj5dbr1YbjacrYgAxVMeF0gK16E3j494mOe7xygM/ZLIguEQ0ETwAg2hlJCtHRGav+y0Ny5A==",
+ "dev": true
+ }
+ }
+ },
+ "esrecurse": {
+ "version": "4.2.1",
+ "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.2.1.tgz",
+ "integrity": "sha512-64RBB++fIOAXPw3P9cy89qfMlvZEXZkqqJkjqqXIvzP5ezRZjW+lPWjw35UX/3EhUPFYbg5ER4JYgDw4007/DQ==",
+ "dev": true,
+ "requires": {
+ "estraverse": "^4.1.0"
+ }
+ },
+ "estraverse": {
+ "version": "4.3.0",
+ "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-4.3.0.tgz",
+ "integrity": "sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==",
+ "dev": true
+ },
+ "esutils": {
+ "version": "2.0.3",
+ "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz",
+ "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==",
+ "dev": true
+ },
+ "event-target-shim": {
+ "version": "5.0.1",
+ "resolved": "https://registry.npmjs.org/event-target-shim/-/event-target-shim-5.0.1.tgz",
+ "integrity": "sha512-i/2XbnSz/uxRCU6+NdVJgKWDTM427+MqYbkQzD321DuCQJUqOuJKIA0IM2+W2xtYHdKOmZ4dR6fExsd4SXL+WQ=="
+ },
+ "external-editor": {
+ "version": "3.1.0",
+ "resolved": "https://registry.npmjs.org/external-editor/-/external-editor-3.1.0.tgz",
+ "integrity": "sha512-hMQ4CX1p1izmuLYyZqLMO/qGNw10wSv9QDCPfzXfyFrOaCSSoRfqE1Kf1s5an66J5JZC62NewG+mK49jOCtQew==",
+ "dev": true,
+ "requires": {
+ "chardet": "^0.7.0",
+ "iconv-lite": "^0.4.24",
+ "tmp": "^0.0.33"
+ }
+ },
+ "fast-deep-equal": {
+ "version": "3.1.1",
+ "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.1.tgz",
+ "integrity": "sha512-8UEa58QDLauDNfpbrX55Q9jrGHThw2ZMdOky5Gl1CDtVeJDPVrG4Jxx1N8jw2gkWaff5UUuX1KJd+9zGe2B+ZA==",
+ "dev": true
+ },
+ "fast-json-stable-stringify": {
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz",
+ "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==",
+ "dev": true
+ },
+ "fast-levenshtein": {
+ "version": "2.0.6",
+ "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz",
+ "integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=",
+ "dev": true
+ },
+ "figures": {
+ "version": "3.2.0",
+ "resolved": "https://registry.npmjs.org/figures/-/figures-3.2.0.tgz",
+ "integrity": "sha512-yaduQFRKLXYOGgEn6AZau90j3ggSOyiqXU0F9JZfeXYhNa+Jk4X+s45A2zg5jns87GAFa34BBm2kXw4XpNcbdg==",
+ "dev": true,
+ "requires": {
+ "escape-string-regexp": "^1.0.5"
+ }
+ },
+ "file-entry-cache": {
+ "version": "5.0.1",
+ "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-5.0.1.tgz",
+ "integrity": "sha512-bCg29ictuBaKUwwArK4ouCaqDgLZcysCFLmM/Yn/FDoqndh/9vNuQfXRDvTuXKLxfD/JtZQGKFT8MGcJBK644g==",
+ "dev": true,
+ "requires": {
+ "flat-cache": "^2.0.1"
+ }
+ },
+ "find-cache-dir": {
+ "version": "3.3.1",
+ "resolved": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-3.3.1.tgz",
+ "integrity": "sha512-t2GDMt3oGC/v+BMwzmllWDuJF/xcDtE5j/fCGbqDD7OLuJkj0cfh1YSA5VKPvwMeLFLNDBkwOKZ2X85jGLVftQ==",
+ "requires": {
+ "commondir": "^1.0.1",
+ "make-dir": "^3.0.2",
+ "pkg-dir": "^4.1.0"
+ }
+ },
+ "find-up": {
+ "version": "4.1.0",
+ "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz",
+ "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==",
+ "requires": {
+ "locate-path": "^5.0.0",
+ "path-exists": "^4.0.0"
+ }
+ },
+ "flat-cache": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-2.0.1.tgz",
+ "integrity": "sha512-LoQe6yDuUMDzQAEH8sgmh4Md6oZnc/7PjtwjNFSzveXqSHt6ka9fPBuso7IGf9Rz4uqnSnWiFH2B/zj24a5ReA==",
+ "dev": true,
+ "requires": {
+ "flatted": "^2.0.0",
+ "rimraf": "2.6.3",
+ "write": "1.0.3"
+ },
+ "dependencies": {
+ "rimraf": {
+ "version": "2.6.3",
+ "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.3.tgz",
+ "integrity": "sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==",
+ "dev": true,
+ "requires": {
+ "glob": "^7.1.3"
+ }
+ }
+ }
+ },
+ "flatted": {
+ "version": "2.0.2",
+ "resolved": "https://registry.npmjs.org/flatted/-/flatted-2.0.2.tgz",
+ "integrity": "sha512-r5wGx7YeOwNWNlCA0wQ86zKyDLMQr+/RB8xy74M4hTphfmjlijTSSXGuH8rnvKZnfT9i+75zmd8jcKdMR4O6jA==",
+ "dev": true
+ },
+ "foreground-child": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-2.0.0.tgz",
+ "integrity": "sha512-dCIq9FpEcyQyXKCkyzmlPTFNgrCzPudOe+mhvJU5zAtlBnGVy2yKxtfsxK2tQBThwq225jcvBjpw1Gr40uzZCA==",
+ "requires": {
+ "cross-spawn": "^7.0.0",
+ "signal-exit": "^3.0.2"
+ }
+ },
+ "fromentries": {
+ "version": "1.2.0",
+ "resolved": "https://registry.npmjs.org/fromentries/-/fromentries-1.2.0.tgz",
+ "integrity": "sha512-33X7H/wdfO99GdRLLgkjUrD4geAFdq/Uv0kl3HD4da6HDixd2GUg8Mw7dahLCV9r/EARkmtYBB6Tch4EEokFTQ=="
+ },
+ "fs-minipass": {
+ "version": "1.2.7",
+ "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-1.2.7.tgz",
+ "integrity": "sha512-GWSSJGFy4e9GUeCcbIkED+bgAoFyj7XF1mV8rma3QW4NIqX9Kyx79N/PF61H5udOV3aY1IaMLs6pGbH71nlCTA==",
+ "requires": {
+ "minipass": "^2.6.0"
+ }
+ },
+ "fs.realpath": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz",
+ "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8="
+ },
+ "function-bind": {
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz",
+ "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==",
+ "dev": true
+ },
+ "functional-red-black-tree": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz",
+ "integrity": "sha1-GwqzvVU7Kg1jmdKcDj6gslIHgyc=",
+ "dev": true
+ },
+ "gauge": {
+ "version": "2.7.4",
+ "resolved": "https://registry.npmjs.org/gauge/-/gauge-2.7.4.tgz",
+ "integrity": "sha1-LANAXHU4w51+s3sxcCLjJfsBi/c=",
+ "requires": {
+ "aproba": "^1.0.3",
+ "console-control-strings": "^1.0.0",
+ "has-unicode": "^2.0.0",
+ "object-assign": "^4.1.0",
+ "signal-exit": "^3.0.0",
+ "string-width": "^1.0.1",
+ "strip-ansi": "^3.0.1",
+ "wide-align": "^1.1.0"
+ },
+ "dependencies": {
+ "ansi-regex": {
+ "version": "2.1.1",
+ "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz",
+ "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8="
+ },
+ "is-fullwidth-code-point": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz",
+ "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=",
+ "requires": {
+ "number-is-nan": "^1.0.0"
+ }
+ },
+ "string-width": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz",
+ "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=",
+ "requires": {
+ "code-point-at": "^1.0.0",
+ "is-fullwidth-code-point": "^1.0.0",
+ "strip-ansi": "^3.0.0"
+ }
+ },
+ "strip-ansi": {
+ "version": "3.0.1",
+ "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz",
+ "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=",
+ "requires": {
+ "ansi-regex": "^2.0.0"
+ }
+ }
+ }
+ },
+ "gensync": {
+ "version": "1.0.0-beta.1",
+ "resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.1.tgz",
+ "integrity": "sha512-r8EC6NO1sngH/zdD9fiRDLdcgnbayXah+mLgManTaIZJqEC1MZstmnox8KpnI2/fxQwrp5OpCOYWLp4rBl4Jcg=="
+ },
+ "get-caller-file": {
+ "version": "2.0.5",
+ "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz",
+ "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg=="
+ },
+ "glob": {
+ "version": "7.1.6",
+ "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz",
+ "integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==",
+ "requires": {
+ "fs.realpath": "^1.0.0",
+ "inflight": "^1.0.4",
+ "inherits": "2",
+ "minimatch": "^3.0.4",
+ "once": "^1.3.0",
+ "path-is-absolute": "^1.0.0"
+ }
+ },
+ "glob-parent": {
+ "version": "5.1.1",
+ "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.1.tgz",
+ "integrity": "sha512-FnI+VGOpnlGHWZxthPGR+QhR78fuiK0sNLkHQv+bL9fQi57lNNdquIbna/WrfROrolq8GK5Ek6BiMwqL/voRYQ==",
+ "dev": true,
+ "requires": {
+ "is-glob": "^4.0.1"
+ }
+ },
+ "globals": {
+ "version": "11.12.0",
+ "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz",
+ "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA=="
+ },
+ "graceful-fs": {
+ "version": "4.2.3",
+ "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.3.tgz",
+ "integrity": "sha512-a30VEBm4PEdx1dRB7MFK7BejejvCvBronbLjht+sHuGYj8PHs7M/5Z+rt5lw551vZ7yfTCj4Vuyy3mSJytDWRQ=="
+ },
+ "has": {
+ "version": "1.0.3",
+ "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz",
+ "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==",
+ "dev": true,
+ "requires": {
+ "function-bind": "^1.1.1"
+ }
+ },
+ "has-flag": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz",
+ "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ=="
+ },
+ "has-symbols": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.1.tgz",
+ "integrity": "sha512-PLcsoqu++dmEIZB+6totNFKq/7Do+Z0u4oT0zKOJNl3lYK6vGwwu2hjHs+68OEZbTjiUE9bgOABXbP/GvrS0Kg==",
+ "dev": true
+ },
+ "has-unicode": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/has-unicode/-/has-unicode-2.0.1.tgz",
+ "integrity": "sha1-4Ob+aijPUROIVeCG0Wkedx3iqLk="
+ },
+ "hasha": {
+ "version": "5.2.0",
+ "resolved": "https://registry.npmjs.org/hasha/-/hasha-5.2.0.tgz",
+ "integrity": "sha512-2W+jKdQbAdSIrggA8Q35Br8qKadTrqCTC8+XZvBWepKDK6m9XkX6Iz1a2yh2KP01kzAR/dpuMeUnocoLYDcskw==",
+ "requires": {
+ "is-stream": "^2.0.0",
+ "type-fest": "^0.8.0"
+ }
+ },
+ "hastebin-gen": {
+ "version": "2.0.5",
+ "resolved": "https://registry.npmjs.org/hastebin-gen/-/hastebin-gen-2.0.5.tgz",
+ "integrity": "sha512-At1LaKtcqh2jiP8xfE2sDGT9IshIki6FqsgLwn2y7FzAvlFJRtpUsSPh3yWjWIQIvxi/GPF07IBqSI8WhPL/gQ==",
+ "requires": {
+ "node-fetch": "^2.6.0"
+ }
+ },
+ "hosted-git-info": {
+ "version": "2.8.8",
+ "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.8.8.tgz",
+ "integrity": "sha512-f/wzC2QaWBs7t9IYqB4T3sR1xviIViXJRJTWBlx2Gf3g0Xi5vI7Yy4koXQ1c9OYDGHN9sBy1DQ2AB8fqZBWhUg==",
+ "dev": true
+ },
+ "html-entities": {
+ "version": "1.3.1",
+ "resolved": "https://registry.npmjs.org/html-entities/-/html-entities-1.3.1.tgz",
+ "integrity": "sha512-rhE/4Z3hIhzHAUKbW8jVcCyuT5oJCXXqhN/6mXXVCpzTmvJnoH2HL/bt3EZ6p55jbFJBeAe1ZNpL5BugLujxNA=="
+ },
+ "html-escaper": {
+ "version": "2.0.2",
+ "resolved": "https://registry.npmjs.org/html-escaper/-/html-escaper-2.0.2.tgz",
+ "integrity": "sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg=="
+ },
+ "https-proxy-agent": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-4.0.0.tgz",
+ "integrity": "sha512-zoDhWrkR3of1l9QAL8/scJZyLu8j/gBkcwcaQOZh7Gyh/+uJQzGVETdgT30akuwkpL8HTRfssqI3BZuV18teDg==",
+ "requires": {
+ "agent-base": "5",
+ "debug": "4"
+ }
+ },
+ "iconv-lite": {
+ "version": "0.4.24",
+ "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz",
+ "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==",
+ "requires": {
+ "safer-buffer": ">= 2.1.2 < 3"
+ }
+ },
+ "ignore": {
+ "version": "4.0.6",
+ "resolved": "https://registry.npmjs.org/ignore/-/ignore-4.0.6.tgz",
+ "integrity": "sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg==",
+ "dev": true
+ },
+ "ignore-walk": {
+ "version": "3.0.3",
+ "resolved": "https://registry.npmjs.org/ignore-walk/-/ignore-walk-3.0.3.tgz",
+ "integrity": "sha512-m7o6xuOaT1aqheYHKf8W6J5pYH85ZI9w077erOzLje3JsB1gkafkAhHHY19dqjulgIZHFm32Cp5uNZgcQqdJKw==",
+ "requires": {
+ "minimatch": "^3.0.4"
+ }
+ },
+ "import-fresh": {
+ "version": "3.2.1",
+ "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.2.1.tgz",
+ "integrity": "sha512-6e1q1cnWP2RXD9/keSkxHScg508CdXqXWgWBaETNhyuBFz+kUZlKboh+ISK+bU++DmbHimVBrOz/zzPe0sZ3sQ==",
+ "dev": true,
+ "requires": {
+ "parent-module": "^1.0.0",
+ "resolve-from": "^4.0.0"
+ },
+ "dependencies": {
+ "resolve-from": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz",
+ "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==",
+ "dev": true
+ }
+ }
+ },
+ "imurmurhash": {
+ "version": "0.1.4",
+ "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz",
+ "integrity": "sha1-khi5srkoojixPcT7a21XbyMUU+o="
+ },
+ "indent-string": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-4.0.0.tgz",
+ "integrity": "sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg=="
+ },
+ "inflight": {
+ "version": "1.0.6",
+ "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz",
+ "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=",
+ "requires": {
+ "once": "^1.3.0",
+ "wrappy": "1"
+ }
+ },
+ "inherits": {
+ "version": "2.0.4",
+ "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz",
+ "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ=="
+ },
+ "ini": {
+ "version": "1.3.5",
+ "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.5.tgz",
+ "integrity": "sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw=="
+ },
+ "inquirer": {
+ "version": "7.1.0",
+ "resolved": "https://registry.npmjs.org/inquirer/-/inquirer-7.1.0.tgz",
+ "integrity": "sha512-5fJMWEmikSYu0nv/flMc475MhGbB7TSPd/2IpFV4I4rMklboCH2rQjYY5kKiYGHqUF9gvaambupcJFFG9dvReg==",
+ "dev": true,
+ "requires": {
+ "ansi-escapes": "^4.2.1",
+ "chalk": "^3.0.0",
+ "cli-cursor": "^3.1.0",
+ "cli-width": "^2.0.0",
+ "external-editor": "^3.0.3",
+ "figures": "^3.0.0",
+ "lodash": "^4.17.15",
+ "mute-stream": "0.0.8",
+ "run-async": "^2.4.0",
+ "rxjs": "^6.5.3",
+ "string-width": "^4.1.0",
+ "strip-ansi": "^6.0.0",
+ "through": "^2.3.6"
+ },
+ "dependencies": {
+ "chalk": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/chalk/-/chalk-3.0.0.tgz",
+ "integrity": "sha512-4D3B6Wf41KOYRFdszmDqMCGq5VV/uMAB273JILmO+3jAlh8X4qDtdtgCR3fxtbLEMzSx22QdhnDcJvu2u1fVwg==",
+ "dev": true,
+ "requires": {
+ "ansi-styles": "^4.1.0",
+ "supports-color": "^7.1.0"
+ }
+ }
+ }
+ },
+ "is-arrayish": {
+ "version": "0.2.1",
+ "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz",
+ "integrity": "sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0=",
+ "dev": true
+ },
+ "is-callable": {
+ "version": "1.1.5",
+ "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.1.5.tgz",
+ "integrity": "sha512-ESKv5sMCJB2jnHTWZ3O5itG+O128Hsus4K4Qh1h2/cgn2vbgnLSVqfV46AeJA9D5EeeLa9w81KUXMtn34zhX+Q==",
+ "dev": true
+ },
+ "is-date-object": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.2.tgz",
+ "integrity": "sha512-USlDT524woQ08aoZFzh3/Z6ch9Y/EWXEHQ/AaRN0SkKq4t2Jw2R2339tSXmwuVoY7LLlBCbOIlx2myP/L5zk0g==",
+ "dev": true
+ },
+ "is-docker": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/is-docker/-/is-docker-2.0.0.tgz",
+ "integrity": "sha512-pJEdRugimx4fBMra5z2/5iRdZ63OhYV0vr0Dwm5+xtW4D1FvRkB8hamMIhnWfyJeDdyr/aa7BDyNbtG38VxgoQ=="
+ },
+ "is-extglob": {
+ "version": "2.1.1",
+ "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz",
+ "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=",
+ "dev": true
+ },
+ "is-fullwidth-code-point": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz",
+ "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg=="
+ },
+ "is-glob": {
+ "version": "4.0.1",
+ "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz",
+ "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==",
+ "dev": true,
+ "requires": {
+ "is-extglob": "^2.1.1"
+ }
+ },
+ "is-promise": {
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/is-promise/-/is-promise-2.1.0.tgz",
+ "integrity": "sha1-eaKp7OfwlugPNtKy87wWwf9L8/o=",
+ "dev": true
+ },
+ "is-regex": {
+ "version": "1.0.5",
+ "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.0.5.tgz",
+ "integrity": "sha512-vlKW17SNq44owv5AQR3Cq0bQPEb8+kF3UKZ2fiZNOWtztYE5i0CzCZxFDwO58qAOWtxdBRVO/V5Qin1wjCqFYQ==",
+ "dev": true,
+ "requires": {
+ "has": "^1.0.3"
+ }
+ },
+ "is-stream": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.0.tgz",
+ "integrity": "sha512-XCoy+WlUr7d1+Z8GgSuXmpuUFC9fOhRXglJMx+dwLKTkL44Cjd4W1Z5P+BQZpr+cR93aGP4S/s7Ftw6Nd/kiEw=="
+ },
+ "is-string": {
+ "version": "1.0.5",
+ "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.5.tgz",
+ "integrity": "sha512-buY6VNRjhQMiF1qWDouloZlQbRhDPCebwxSjxMjxgemYT46YMd2NR0/H+fBhEfWX4A/w9TBJ+ol+okqJKFE6vQ==",
+ "dev": true
+ },
+ "is-symbol": {
+ "version": "1.0.3",
+ "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.3.tgz",
+ "integrity": "sha512-OwijhaRSgqvhm/0ZdAcXNZt9lYdKFpcRDT5ULUuYXPoT794UNOdU+gpT6Rzo7b4V2HUl/op6GqY894AZwv9faQ==",
+ "dev": true,
+ "requires": {
+ "has-symbols": "^1.0.1"
+ }
+ },
+ "is-typedarray": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz",
+ "integrity": "sha1-5HnICFjfDBsR3dppQPlgEfzaSpo="
+ },
+ "is-windows": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/is-windows/-/is-windows-1.0.2.tgz",
+ "integrity": "sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA=="
+ },
+ "isarray": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz",
+ "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE="
+ },
+ "isexe": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz",
+ "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA="
+ },
+ "istanbul-lib-coverage": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-3.0.0.tgz",
+ "integrity": "sha512-UiUIqxMgRDET6eR+o5HbfRYP1l0hqkWOs7vNxC/mggutCMUIhWMm8gAHb8tHlyfD3/l6rlgNA5cKdDzEAf6hEg=="
+ },
+ "istanbul-lib-hook": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/istanbul-lib-hook/-/istanbul-lib-hook-3.0.0.tgz",
+ "integrity": "sha512-Pt/uge1Q9s+5VAZ+pCo16TYMWPBIl+oaNIjgLQxcX0itS6ueeaA+pEfThZpH8WxhFgCiEb8sAJY6MdUKgiIWaQ==",
+ "requires": {
+ "append-transform": "^2.0.0"
+ }
+ },
+ "istanbul-lib-instrument": {
+ "version": "4.0.1",
+ "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-4.0.1.tgz",
+ "integrity": "sha512-imIchxnodll7pvQBYOqUu88EufLCU56LMeFPZZM/fJZ1irYcYdqroaV+ACK1Ila8ls09iEYArp+nqyC6lW1Vfg==",
+ "requires": {
+ "@babel/core": "^7.7.5",
+ "@babel/parser": "^7.7.5",
+ "@babel/template": "^7.7.4",
+ "@babel/traverse": "^7.7.4",
+ "@istanbuljs/schema": "^0.1.2",
+ "istanbul-lib-coverage": "^3.0.0",
+ "semver": "^6.3.0"
+ }
+ },
+ "istanbul-lib-processinfo": {
+ "version": "2.0.2",
+ "resolved": "https://registry.npmjs.org/istanbul-lib-processinfo/-/istanbul-lib-processinfo-2.0.2.tgz",
+ "integrity": "sha512-kOwpa7z9hme+IBPZMzQ5vdQj8srYgAtaRqeI48NGmAQ+/5yKiHLV0QbYqQpxsdEF0+w14SoB8YbnHKcXE2KnYw==",
+ "requires": {
+ "archy": "^1.0.0",
+ "cross-spawn": "^7.0.0",
+ "istanbul-lib-coverage": "^3.0.0-alpha.1",
+ "make-dir": "^3.0.0",
+ "p-map": "^3.0.0",
+ "rimraf": "^3.0.0",
+ "uuid": "^3.3.3"
+ }
+ },
+ "istanbul-lib-report": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/istanbul-lib-report/-/istanbul-lib-report-3.0.0.tgz",
+ "integrity": "sha512-wcdi+uAKzfiGT2abPpKZ0hSU1rGQjUQnLvtY5MpQ7QCTahD3VODhcu4wcfY1YtkGaDD5yuydOLINXsfbus9ROw==",
+ "requires": {
+ "istanbul-lib-coverage": "^3.0.0",
+ "make-dir": "^3.0.0",
+ "supports-color": "^7.1.0"
+ }
+ },
+ "istanbul-lib-source-maps": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-4.0.0.tgz",
+ "integrity": "sha512-c16LpFRkR8vQXyHZ5nLpY35JZtzj1PQY1iZmesUbf1FZHbIupcWfjgOXBY9YHkLEQ6puz1u4Dgj6qmU/DisrZg==",
+ "requires": {
+ "debug": "^4.1.1",
+ "istanbul-lib-coverage": "^3.0.0",
+ "source-map": "^0.6.1"
+ },
+ "dependencies": {
+ "source-map": {
+ "version": "0.6.1",
+ "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz",
+ "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g=="
+ }
+ }
+ },
+ "istanbul-reports": {
+ "version": "3.0.2",
+ "resolved": "https://registry.npmjs.org/istanbul-reports/-/istanbul-reports-3.0.2.tgz",
+ "integrity": "sha512-9tZvz7AiR3PEDNGiV9vIouQ/EAcqMXFmkcA1CDFTwOB98OZVDL0PH9glHotf5Ugp6GCOTypfzGWI/OqjWNCRUw==",
+ "requires": {
+ "html-escaper": "^2.0.0",
+ "istanbul-lib-report": "^3.0.0"
+ }
+ },
+ "js-tokens": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz",
+ "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ=="
+ },
+ "js-yaml": {
+ "version": "3.13.1",
+ "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.13.1.tgz",
+ "integrity": "sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw==",
+ "requires": {
+ "argparse": "^1.0.7",
+ "esprima": "^4.0.0"
+ }
+ },
+ "jsesc": {
+ "version": "2.5.2",
+ "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz",
+ "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA=="
+ },
+ "json-schema-traverse": {
+ "version": "0.4.1",
+ "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz",
+ "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==",
+ "dev": true
+ },
+ "json-stable-stringify-without-jsonify": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz",
+ "integrity": "sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE=",
+ "dev": true
+ },
+ "json5": {
+ "version": "2.1.3",
+ "resolved": "https://registry.npmjs.org/json5/-/json5-2.1.3.tgz",
+ "integrity": "sha512-KXPvOm8K9IJKFM0bmdn8QXh7udDh1g/giieX0NLCaMnb4hEiVFqnop2ImTXCc5e0/oHz3LTqmHGtExn5hfMkOA==",
+ "requires": {
+ "minimist": "^1.2.5"
+ }
+ },
+ "kareem": {
+ "version": "2.3.1",
+ "resolved": "https://registry.npmjs.org/kareem/-/kareem-2.3.1.tgz",
+ "integrity": "sha512-l3hLhffs9zqoDe8zjmb/mAN4B8VT3L56EUvKNqLFVs9YlFA+zx7ke1DO8STAdDyYNkeSo1nKmjuvQeI12So8Xw=="
+ },
+ "levn": {
+ "version": "0.3.0",
+ "resolved": "https://registry.npmjs.org/levn/-/levn-0.3.0.tgz",
+ "integrity": "sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4=",
+ "dev": true,
+ "requires": {
+ "prelude-ls": "~1.1.2",
+ "type-check": "~0.3.2"
+ }
+ },
+ "load-json-file": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-2.0.0.tgz",
+ "integrity": "sha1-eUfkIUmvgNaWy/eXvKq8/h/inKg=",
+ "dev": true,
+ "requires": {
+ "graceful-fs": "^4.1.2",
+ "parse-json": "^2.2.0",
+ "pify": "^2.0.0",
+ "strip-bom": "^3.0.0"
+ },
+ "dependencies": {
+ "strip-bom": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz",
+ "integrity": "sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM=",
+ "dev": true
+ }
+ }
+ },
+ "locate-path": {
+ "version": "5.0.0",
+ "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz",
+ "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==",
+ "requires": {
+ "p-locate": "^4.1.0"
+ }
+ },
+ "lodash": {
+ "version": "4.17.15",
+ "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.15.tgz",
+ "integrity": "sha512-8xOcRHvCjnocdS5cpwXQXVzmmh5e5+saE2QGoeQmbKmRS6J3VQppPOIt0MnmE+4xlZoumy0GPG0D0MVIQbNA1A=="
+ },
+ "lodash.flattendeep": {
+ "version": "4.4.0",
+ "resolved": "https://registry.npmjs.org/lodash.flattendeep/-/lodash.flattendeep-4.4.0.tgz",
+ "integrity": "sha1-+wMJF/hqMTTlvJvsDWngAT3f7bI="
+ },
+ "lru_map": {
+ "version": "0.3.3",
+ "resolved": "https://registry.npmjs.org/lru_map/-/lru_map-0.3.3.tgz",
+ "integrity": "sha1-tcg1G5Rky9dQM1p5ZQoOwOVhGN0="
+ },
+ "m3u8stream": {
+ "version": "0.6.5",
+ "resolved": "https://registry.npmjs.org/m3u8stream/-/m3u8stream-0.6.5.tgz",
+ "integrity": "sha512-QZCzhcfUliZfsOboi68QkNcMejPKTEhxE+s1TApvHubDeR8ythm4ViWuYFqgUwZeoHe8q0nsPxOvA3lQvdSzyg==",
+ "requires": {
+ "miniget": "^1.6.1",
+ "sax": "^1.2.4"
+ }
+ },
+ "make-dir": {
+ "version": "3.0.2",
+ "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-3.0.2.tgz",
+ "integrity": "sha512-rYKABKutXa6vXTXhoV18cBE7PaewPXHe/Bdq4v+ZLMhxbWApkFFplT0LcbMW+6BbjnQXzZ/sAvSE/JdguApG5w==",
+ "requires": {
+ "semver": "^6.0.0"
+ }
+ },
+ "memory-pager": {
+ "version": "1.5.0",
+ "resolved": "https://registry.npmjs.org/memory-pager/-/memory-pager-1.5.0.tgz",
+ "integrity": "sha512-ZS4Bp4r/Zoeq6+NLJpP+0Zzm0pR8whtGPf1XExKLJBAczGMnSi3It14OiNCStjQjM6NU1okjQGSxgEZN8eBYKg==",
+ "optional": true
+ },
+ "mime-db": {
+ "version": "1.43.0",
+ "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.43.0.tgz",
+ "integrity": "sha512-+5dsGEEovYbT8UY9yD7eE4XTc4UwJ1jBYlgaQQF38ENsKR3wj/8q8RFZrF9WIZpB2V1ArTVFUva8sAul1NzRzQ=="
+ },
+ "mime-types": {
+ "version": "2.1.26",
+ "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.26.tgz",
+ "integrity": "sha512-01paPWYgLrkqAyrlDorC1uDwl2p3qZT7yl806vW7DvDoxwXi46jsjFbg+WdwotBIk6/MbEhO/dh5aZ5sNj/dWQ==",
+ "requires": {
+ "mime-db": "1.43.0"
+ }
+ },
+ "mimic-fn": {
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz",
+ "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==",
+ "dev": true
+ },
+ "miniget": {
+ "version": "1.7.0",
+ "resolved": "https://registry.npmjs.org/miniget/-/miniget-1.7.0.tgz",
+ "integrity": "sha512-yrgaDSMRzrfYTkudB4Y6xK8pCb7oAH2bvfv6iPY2m6CedZfs9yK4b/ofh0Vzv08hCYXH/HHkoS8an6fkWtOAQA=="
+ },
+ "minimatch": {
+ "version": "3.0.4",
+ "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz",
+ "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==",
+ "requires": {
+ "brace-expansion": "^1.1.7"
+ }
+ },
+ "minimist": {
+ "version": "1.2.5",
+ "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz",
+ "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw=="
+ },
+ "minipass": {
+ "version": "2.9.0",
+ "resolved": "https://registry.npmjs.org/minipass/-/minipass-2.9.0.tgz",
+ "integrity": "sha512-wxfUjg9WebH+CUDX/CdbRlh5SmfZiy/hpkxaRI16Y9W56Pa75sWgd/rvFilSgrauD9NyFymP/+JFV3KwzIsJeg==",
+ "requires": {
+ "safe-buffer": "^5.1.2",
+ "yallist": "^3.0.0"
+ }
+ },
+ "minizlib": {
+ "version": "1.3.3",
+ "resolved": "https://registry.npmjs.org/minizlib/-/minizlib-1.3.3.tgz",
+ "integrity": "sha512-6ZYMOEnmVsdCeTJVE0W9ZD+pVnE8h9Hma/iOwwRDsdQoePpoX56/8B6z3P9VNwppJuBKNRuFDRNRqRWexT9G9Q==",
+ "requires": {
+ "minipass": "^2.9.0"
+ }
+ },
+ "mkdirp": {
+ "version": "0.5.4",
+ "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.4.tgz",
+ "integrity": "sha512-iG9AK/dJLtJ0XNgTuDbSyNS3zECqDlAhnQW4CsNxBG3LQJBbHmRX1egw39DmtOdCAqY+dKXV+sgPgilNWUKMVw==",
+ "requires": {
+ "minimist": "^1.2.5"
+ }
+ },
+ "moment": {
+ "version": "2.24.0",
+ "resolved": "https://registry.npmjs.org/moment/-/moment-2.24.0.tgz",
+ "integrity": "sha512-bV7f+6l2QigeBBZSM/6yTNq4P2fNpSWj/0e7jQcy87A8e7o2nAfP/34/2ky5Vw4B9S446EtIhodAzkFCcR4dQg=="
+ },
+ "mongodb": {
+ "version": "3.5.5",
+ "resolved": "https://registry.npmjs.org/mongodb/-/mongodb-3.5.5.tgz",
+ "integrity": "sha512-GCjDxR3UOltDq00Zcpzql6dQo1sVry60OXJY3TDmFc2SWFY6c8Gn1Ardidc5jDirvJrx2GC3knGOImKphbSL3A==",
+ "requires": {
+ "bl": "^2.2.0",
+ "bson": "^1.1.1",
+ "denque": "^1.4.1",
+ "require_optional": "^1.0.1",
+ "safe-buffer": "^5.1.2",
+ "saslprep": "^1.0.0"
+ }
+ },
+ "mongoose": {
+ "version": "5.9.9",
+ "resolved": "https://registry.npmjs.org/mongoose/-/mongoose-5.9.9.tgz",
+ "integrity": "sha512-pLkIkM7XQwfbQ+xK1l57Zv0DYPH190/I6Cv5+PbJGfAU0HvX0atMlp+vly8zcjNTEvTkVM80qA5eBYBvZyLYXw==",
+ "requires": {
+ "bson": "~1.1.1",
+ "kareem": "2.3.1",
+ "mongodb": "3.5.5",
+ "mongoose-legacy-pluralize": "1.0.2",
+ "mpath": "0.7.0",
+ "mquery": "3.2.2",
+ "ms": "2.1.2",
+ "regexp-clone": "1.0.0",
+ "safe-buffer": "5.1.2",
+ "sift": "7.0.1",
+ "sliced": "1.0.1"
+ }
+ },
+ "mongoose-legacy-pluralize": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/mongoose-legacy-pluralize/-/mongoose-legacy-pluralize-1.0.2.tgz",
+ "integrity": "sha512-Yo/7qQU4/EyIS8YDFSeenIvXxZN+ld7YdV9LqFVQJzTLye8unujAWPZ4NWKfFA+RNjh+wvTWKY9Z3E5XM6ZZiQ=="
+ },
+ "mpath": {
+ "version": "0.7.0",
+ "resolved": "https://registry.npmjs.org/mpath/-/mpath-0.7.0.tgz",
+ "integrity": "sha512-Aiq04hILxhz1L+f7sjGyn7IxYzWm1zLNNXcfhDtx04kZ2Gk7uvFdgZ8ts1cWa/6d0TQmag2yR8zSGZUmp0tFNg=="
+ },
+ "mquery": {
+ "version": "3.2.2",
+ "resolved": "https://registry.npmjs.org/mquery/-/mquery-3.2.2.tgz",
+ "integrity": "sha512-XB52992COp0KP230I3qloVUbkLUxJIu328HBP2t2EsxSFtf4W1HPSOBWOXf1bqxK4Xbb66lfMJ+Bpfd9/yZE1Q==",
+ "requires": {
+ "bluebird": "3.5.1",
+ "debug": "3.1.0",
+ "regexp-clone": "^1.0.0",
+ "safe-buffer": "5.1.2",
+ "sliced": "1.0.1"
+ },
+ "dependencies": {
+ "debug": {
+ "version": "3.1.0",
+ "resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz",
+ "integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==",
+ "requires": {
+ "ms": "2.0.0"
+ }
+ },
+ "ms": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz",
+ "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g="
+ }
+ }
+ },
+ "ms": {
+ "version": "2.1.2",
+ "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz",
+ "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w=="
+ },
+ "mute-stream": {
+ "version": "0.0.8",
+ "resolved": "https://registry.npmjs.org/mute-stream/-/mute-stream-0.0.8.tgz",
+ "integrity": "sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA==",
+ "dev": true
+ },
+ "natural-compare": {
+ "version": "1.4.0",
+ "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz",
+ "integrity": "sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc=",
+ "dev": true
+ },
+ "needle": {
+ "version": "2.4.1",
+ "resolved": "https://registry.npmjs.org/needle/-/needle-2.4.1.tgz",
+ "integrity": "sha512-x/gi6ijr4B7fwl6WYL9FwlCvRQKGlUNvnceho8wxkwXqN8jvVmmmATTmZPRRG7b/yC1eode26C2HO9jl78Du9g==",
+ "requires": {
+ "debug": "^3.2.6",
+ "iconv-lite": "^0.4.4",
+ "sax": "^1.2.4"
+ },
+ "dependencies": {
+ "debug": {
+ "version": "3.2.6",
+ "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.6.tgz",
+ "integrity": "sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ==",
+ "requires": {
+ "ms": "^2.1.1"
+ }
+ }
+ }
+ },
+ "nice-try": {
+ "version": "1.0.5",
+ "resolved": "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz",
+ "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==",
+ "dev": true
+ },
+ "node-addon-api": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/node-addon-api/-/node-addon-api-2.0.0.tgz",
+ "integrity": "sha512-ASCL5U13as7HhOExbT6OlWJJUV/lLzL2voOSP1UVehpRD8FbSrSDjfScK/KwAvVTI5AS6r4VwbOMlIqtvRidnA=="
+ },
+ "node-fetch": {
+ "version": "2.6.0",
+ "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.6.0.tgz",
+ "integrity": "sha512-8dG4H5ujfvFiqDmVu9fQ5bOHUC15JMjMY/Zumv26oOvvVJjM67KF8koCWIabKQ1GJIa9r2mMZscBq/TbdOcmNA=="
+ },
+ "node-pre-gyp": {
+ "version": "0.14.0",
+ "resolved": "https://registry.npmjs.org/node-pre-gyp/-/node-pre-gyp-0.14.0.tgz",
+ "integrity": "sha512-+CvDC7ZttU/sSt9rFjix/P05iS43qHCOOGzcr3Ry99bXG7VX953+vFyEuph/tfqoYu8dttBkE86JSKBO2OzcxA==",
+ "requires": {
+ "detect-libc": "^1.0.2",
+ "mkdirp": "^0.5.1",
+ "needle": "^2.2.1",
+ "nopt": "^4.0.1",
+ "npm-packlist": "^1.1.6",
+ "npmlog": "^4.0.2",
+ "rc": "^1.2.7",
+ "rimraf": "^2.6.1",
+ "semver": "^5.3.0",
+ "tar": "^4.4.2"
+ },
+ "dependencies": {
+ "rimraf": {
+ "version": "2.7.1",
+ "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.7.1.tgz",
+ "integrity": "sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==",
+ "requires": {
+ "glob": "^7.1.3"
+ }
+ },
+ "semver": {
+ "version": "5.7.1",
+ "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz",
+ "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ=="
+ }
+ }
+ },
+ "node-preload": {
+ "version": "0.2.1",
+ "resolved": "https://registry.npmjs.org/node-preload/-/node-preload-0.2.1.tgz",
+ "integrity": "sha512-RM5oyBy45cLEoHqCeh+MNuFAxO0vTFBLskvQbOKnEE7YTTSN4tbN8QWDIPQ6L+WvKsB/qLEGpYe2ZZ9d4W9OIQ==",
+ "requires": {
+ "process-on-spawn": "^1.0.0"
+ }
+ },
+ "nopt": {
+ "version": "4.0.3",
+ "resolved": "https://registry.npmjs.org/nopt/-/nopt-4.0.3.tgz",
+ "integrity": "sha512-CvaGwVMztSMJLOeXPrez7fyfObdZqNUK1cPAEzLHrTybIua9pMdmmPR5YwtfNftIOMv3DPUhFaxsZMNTQO20Kg==",
+ "requires": {
+ "abbrev": "1",
+ "osenv": "^0.1.4"
+ }
+ },
+ "normalize-package-data": {
+ "version": "2.5.0",
+ "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-2.5.0.tgz",
+ "integrity": "sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==",
+ "dev": true,
+ "requires": {
+ "hosted-git-info": "^2.1.4",
+ "resolve": "^1.10.0",
+ "semver": "2 || 3 || 4 || 5",
+ "validate-npm-package-license": "^3.0.1"
+ },
+ "dependencies": {
+ "semver": {
+ "version": "5.7.1",
+ "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz",
+ "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==",
+ "dev": true
+ }
+ }
+ },
+ "npm-bundled": {
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/npm-bundled/-/npm-bundled-1.1.1.tgz",
+ "integrity": "sha512-gqkfgGePhTpAEgUsGEgcq1rqPXA+tv/aVBlgEzfXwA1yiUJF7xtEt3CtVwOjNYQOVknDk0F20w58Fnm3EtG0fA==",
+ "requires": {
+ "npm-normalize-package-bin": "^1.0.1"
+ }
+ },
+ "npm-normalize-package-bin": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/npm-normalize-package-bin/-/npm-normalize-package-bin-1.0.1.tgz",
+ "integrity": "sha512-EPfafl6JL5/rU+ot6P3gRSCpPDW5VmIzX959Ob1+ySFUuuYHWHekXpwdUZcKP5C+DS4GEtdJluwBjnsNDl+fSA=="
+ },
+ "npm-packlist": {
+ "version": "1.4.8",
+ "resolved": "https://registry.npmjs.org/npm-packlist/-/npm-packlist-1.4.8.tgz",
+ "integrity": "sha512-5+AZgwru5IevF5ZdnFglB5wNlHG1AOOuw28WhUq8/8emhBmLv6jX5by4WJCh7lW0uSYZYS6DXqIsyZVIXRZU9A==",
+ "requires": {
+ "ignore-walk": "^3.0.1",
+ "npm-bundled": "^1.0.1",
+ "npm-normalize-package-bin": "^1.0.1"
+ }
+ },
+ "npmlog": {
+ "version": "4.1.2",
+ "resolved": "https://registry.npmjs.org/npmlog/-/npmlog-4.1.2.tgz",
+ "integrity": "sha512-2uUqazuKlTaSI/dC8AzicUck7+IrEaOnN/e0jd3Xtt1KcGpwx30v50mL7oPyr/h9bL3E4aZccVwpwP+5W9Vjkg==",
+ "requires": {
+ "are-we-there-yet": "~1.1.2",
+ "console-control-strings": "~1.1.0",
+ "gauge": "~2.7.3",
+ "set-blocking": "~2.0.0"
+ }
+ },
+ "number-is-nan": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz",
+ "integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0="
+ },
+ "nyc": {
+ "version": "15.0.1",
+ "resolved": "https://registry.npmjs.org/nyc/-/nyc-15.0.1.tgz",
+ "integrity": "sha512-n0MBXYBYRqa67IVt62qW1r/d9UH/Qtr7SF1w/nQLJ9KxvWF6b2xCHImRAixHN9tnMMYHC2P14uo6KddNGwMgGg==",
+ "requires": {
+ "@istanbuljs/load-nyc-config": "^1.0.0",
+ "@istanbuljs/schema": "^0.1.2",
+ "caching-transform": "^4.0.0",
+ "convert-source-map": "^1.7.0",
+ "decamelize": "^1.2.0",
+ "find-cache-dir": "^3.2.0",
+ "find-up": "^4.1.0",
+ "foreground-child": "^2.0.0",
+ "glob": "^7.1.6",
+ "istanbul-lib-coverage": "^3.0.0",
+ "istanbul-lib-hook": "^3.0.0",
+ "istanbul-lib-instrument": "^4.0.0",
+ "istanbul-lib-processinfo": "^2.0.2",
+ "istanbul-lib-report": "^3.0.0",
+ "istanbul-lib-source-maps": "^4.0.0",
+ "istanbul-reports": "^3.0.2",
+ "make-dir": "^3.0.0",
+ "node-preload": "^0.2.1",
+ "p-map": "^3.0.0",
+ "process-on-spawn": "^1.0.0",
+ "resolve-from": "^5.0.0",
+ "rimraf": "^3.0.0",
+ "signal-exit": "^3.0.2",
+ "spawn-wrap": "^2.0.0",
+ "test-exclude": "^6.0.0",
+ "yargs": "^15.0.2"
+ },
+ "dependencies": {
+ "resolve-from": {
+ "version": "5.0.0",
+ "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz",
+ "integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw=="
+ }
+ }
+ },
+ "object-assign": {
+ "version": "4.1.1",
+ "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz",
+ "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM="
+ },
+ "object-inspect": {
+ "version": "1.7.0",
+ "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.7.0.tgz",
+ "integrity": "sha512-a7pEHdh1xKIAgTySUGgLMx/xwDZskN1Ud6egYYN3EdRW4ZMPNEDUTF+hwy2LUC+Bl+SyLXANnwz/jyh/qutKUw==",
+ "dev": true
+ },
+ "object-keys": {
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz",
+ "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==",
+ "dev": true
+ },
+ "object.assign": {
+ "version": "4.1.0",
+ "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.0.tgz",
+ "integrity": "sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w==",
+ "dev": true,
+ "requires": {
+ "define-properties": "^1.1.2",
+ "function-bind": "^1.1.1",
+ "has-symbols": "^1.0.0",
+ "object-keys": "^1.0.11"
+ }
+ },
+ "object.values": {
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/object.values/-/object.values-1.1.1.tgz",
+ "integrity": "sha512-WTa54g2K8iu0kmS/us18jEmdv1a4Wi//BZ/DTVYEcH0XhLM5NYdpDHja3gt57VrZLcNAO2WGA+KpWsDBaHt6eA==",
+ "dev": true,
+ "requires": {
+ "define-properties": "^1.1.3",
+ "es-abstract": "^1.17.0-next.1",
+ "function-bind": "^1.1.1",
+ "has": "^1.0.3"
+ }
+ },
+ "once": {
+ "version": "1.4.0",
+ "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz",
+ "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=",
+ "requires": {
+ "wrappy": "1"
+ }
+ },
+ "onetime": {
+ "version": "5.1.0",
+ "resolved": "https://registry.npmjs.org/onetime/-/onetime-5.1.0.tgz",
+ "integrity": "sha512-5NcSkPHhwTVFIQN+TUqXoS5+dlElHXdpAWu9I0HP20YOtIi+aZ0Ct82jdlILDxjLEAWwvm+qj1m6aEtsDVmm6Q==",
+ "dev": true,
+ "requires": {
+ "mimic-fn": "^2.1.0"
+ }
+ },
+ "optionator": {
+ "version": "0.8.3",
+ "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.8.3.tgz",
+ "integrity": "sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA==",
+ "dev": true,
+ "requires": {
+ "deep-is": "~0.1.3",
+ "fast-levenshtein": "~2.0.6",
+ "levn": "~0.3.0",
+ "prelude-ls": "~1.1.2",
+ "type-check": "~0.3.2",
+ "word-wrap": "~1.2.3"
+ }
+ },
+ "os-homedir": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz",
+ "integrity": "sha1-/7xJiDNuDoM94MFox+8VISGqf7M="
+ },
+ "os-tmpdir": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz",
+ "integrity": "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ="
+ },
+ "osenv": {
+ "version": "0.1.5",
+ "resolved": "https://registry.npmjs.org/osenv/-/osenv-0.1.5.tgz",
+ "integrity": "sha512-0CWcCECdMVc2Rw3U5w9ZjqX6ga6ubk1xDVKxtBQPK7wis/0F2r9T6k4ydGYhecl7YUBxBVxhL5oisPsNxAPe2g==",
+ "requires": {
+ "os-homedir": "^1.0.0",
+ "os-tmpdir": "^1.0.0"
+ }
+ },
+ "p-limit": {
+ "version": "2.3.0",
+ "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz",
+ "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==",
+ "requires": {
+ "p-try": "^2.0.0"
+ }
+ },
+ "p-locate": {
+ "version": "4.1.0",
+ "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz",
+ "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==",
+ "requires": {
+ "p-limit": "^2.2.0"
+ }
+ },
+ "p-map": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/p-map/-/p-map-3.0.0.tgz",
+ "integrity": "sha512-d3qXVTF/s+W+CdJ5A29wywV2n8CQQYahlgz2bFiA+4eVNJbHJodPZ+/gXwPGh0bOqA+j8S+6+ckmvLGPk1QpxQ==",
+ "requires": {
+ "aggregate-error": "^3.0.0"
+ }
+ },
+ "p-try": {
+ "version": "2.2.0",
+ "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz",
+ "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ=="
+ },
+ "package-hash": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/package-hash/-/package-hash-4.0.0.tgz",
+ "integrity": "sha512-whdkPIooSu/bASggZ96BWVvZTRMOFxnyUG5PnTSGKoJE2gd5mbVNmR2Nj20QFzxYYgAXpoqC+AiXzl+UMRh7zQ==",
+ "requires": {
+ "graceful-fs": "^4.1.15",
+ "hasha": "^5.0.0",
+ "lodash.flattendeep": "^4.4.0",
+ "release-zalgo": "^1.0.0"
+ }
+ },
+ "parent-module": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz",
+ "integrity": "sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==",
+ "dev": true,
+ "requires": {
+ "callsites": "^3.0.0"
+ }
+ },
+ "parse-json": {
+ "version": "2.2.0",
+ "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-2.2.0.tgz",
+ "integrity": "sha1-9ID0BDTvgHQfhGkJn43qGPVaTck=",
+ "dev": true,
+ "requires": {
+ "error-ex": "^1.2.0"
+ }
+ },
+ "path-exists": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz",
+ "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w=="
+ },
+ "path-is-absolute": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz",
+ "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18="
+ },
+ "path-key": {
+ "version": "3.1.1",
+ "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz",
+ "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q=="
+ },
+ "path-parse": {
+ "version": "1.0.6",
+ "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.6.tgz",
+ "integrity": "sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw=="
+ },
+ "path-type": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/path-type/-/path-type-2.0.0.tgz",
+ "integrity": "sha1-8BLMuEFbcJb8LaoQVMPXI4lZTHM=",
+ "dev": true,
+ "requires": {
+ "pify": "^2.0.0"
+ }
+ },
+ "pify": {
+ "version": "2.3.0",
+ "resolved": "https://registry.npmjs.org/pify/-/pify-2.3.0.tgz",
+ "integrity": "sha1-7RQaasBDqEnqWISY59yosVMw6Qw=",
+ "dev": true
+ },
+ "pkg-dir": {
+ "version": "4.2.0",
+ "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-4.2.0.tgz",
+ "integrity": "sha512-HRDzbaKjC+AOWVXxAU/x54COGeIv9eb+6CkDSQoNTt4XyWoIJvuPsXizxu/Fr23EiekbtZwmh1IcIG/l/a10GQ==",
+ "requires": {
+ "find-up": "^4.0.0"
+ }
+ },
+ "prelude-ls": {
+ "version": "1.1.2",
+ "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.1.2.tgz",
+ "integrity": "sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ=",
+ "dev": true
+ },
+ "prism-media": {
+ "version": "1.2.1",
+ "resolved": "https://registry.npmjs.org/prism-media/-/prism-media-1.2.1.tgz",
+ "integrity": "sha512-R3EbKwJiYlTvGwcG1DpUt+06DsxOGS5W4AMEHT7oVOjG93MjpdhGX1whHyjnqknylLMupKAsKMEXcTNRbPe6Vw=="
+ },
+ "process-nextick-args": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz",
+ "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag=="
+ },
+ "process-on-spawn": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/process-on-spawn/-/process-on-spawn-1.0.0.tgz",
+ "integrity": "sha512-1WsPDsUSMmZH5LeMLegqkPDrsGgsWwk1Exipy2hvB0o/F0ASzbpIctSCcZIK1ykJvtTJULEH+20WOFjMvGnCTg==",
+ "requires": {
+ "fromentries": "^1.2.0"
+ }
+ },
+ "progress": {
+ "version": "2.0.3",
+ "resolved": "https://registry.npmjs.org/progress/-/progress-2.0.3.tgz",
+ "integrity": "sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA==",
+ "dev": true
+ },
+ "rc": {
+ "version": "1.2.8",
+ "resolved": "https://registry.npmjs.org/rc/-/rc-1.2.8.tgz",
+ "integrity": "sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==",
+ "requires": {
+ "deep-extend": "^0.6.0",
+ "ini": "~1.3.0",
+ "minimist": "^1.2.0",
+ "strip-json-comments": "~2.0.1"
+ },
+ "dependencies": {
+ "strip-json-comments": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz",
+ "integrity": "sha1-PFMZQukIwml8DsNEhYwobHygpgo="
+ }
+ }
+ },
+ "read-pkg": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-2.0.0.tgz",
+ "integrity": "sha1-jvHAYjxqbbDcZxPEv6xGMysjaPg=",
+ "dev": true,
+ "requires": {
+ "load-json-file": "^2.0.0",
+ "normalize-package-data": "^2.3.2",
+ "path-type": "^2.0.0"
+ }
+ },
+ "read-pkg-up": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/read-pkg-up/-/read-pkg-up-2.0.0.tgz",
+ "integrity": "sha1-a3KoBImE4MQeeVEP1en6mbO1Sb4=",
+ "dev": true,
+ "requires": {
+ "find-up": "^2.0.0",
+ "read-pkg": "^2.0.0"
+ },
+ "dependencies": {
+ "find-up": {
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/find-up/-/find-up-2.1.0.tgz",
+ "integrity": "sha1-RdG35QbHF93UgndaK3eSCjwMV6c=",
+ "dev": true,
+ "requires": {
+ "locate-path": "^2.0.0"
+ }
+ },
+ "locate-path": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-2.0.0.tgz",
+ "integrity": "sha1-K1aLJl7slExtnA3pw9u7ygNUzY4=",
+ "dev": true,
+ "requires": {
+ "p-locate": "^2.0.0",
+ "path-exists": "^3.0.0"
+ }
+ },
+ "p-limit": {
+ "version": "1.3.0",
+ "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-1.3.0.tgz",
+ "integrity": "sha512-vvcXsLAJ9Dr5rQOPk7toZQZJApBl2K4J6dANSsEuh6QI41JYcsS/qhTGa9ErIUUgK3WNQoJYvylxvjqmiqEA9Q==",
+ "dev": true,
+ "requires": {
+ "p-try": "^1.0.0"
+ }
+ },
+ "p-locate": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-2.0.0.tgz",
+ "integrity": "sha1-IKAQOyIqcMj9OcwuWAaA893l7EM=",
+ "dev": true,
+ "requires": {
+ "p-limit": "^1.1.0"
+ }
+ },
+ "p-try": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/p-try/-/p-try-1.0.0.tgz",
+ "integrity": "sha1-y8ec26+P1CKOE/Yh8rGiN8GyB7M=",
+ "dev": true
+ },
+ "path-exists": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz",
+ "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=",
+ "dev": true
+ }
+ }
+ },
+ "readable-stream": {
+ "version": "2.3.7",
+ "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz",
+ "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==",
+ "requires": {
+ "core-util-is": "~1.0.0",
+ "inherits": "~2.0.3",
+ "isarray": "~1.0.0",
+ "process-nextick-args": "~2.0.0",
+ "safe-buffer": "~5.1.1",
+ "string_decoder": "~1.1.1",
+ "util-deprecate": "~1.0.1"
+ }
+ },
+ "regexp-clone": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/regexp-clone/-/regexp-clone-1.0.0.tgz",
+ "integrity": "sha512-TuAasHQNamyyJ2hb97IuBEif4qBHGjPHBS64sZwytpLEqtBQ1gPJTnOaQ6qmpET16cK14kkjbazl6+p0RRv0yw=="
+ },
+ "regexpp": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/regexpp/-/regexpp-2.0.1.tgz",
+ "integrity": "sha512-lv0M6+TkDVniA3aD1Eg0DVpfU/booSu7Eev3TDO/mZKHBfVjgCGTV4t4buppESEYDtkArYFOxTJWv6S5C+iaNw==",
+ "dev": true
+ },
+ "release-zalgo": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/release-zalgo/-/release-zalgo-1.0.0.tgz",
+ "integrity": "sha1-CXALflB0Mpc5Mw5TXFqQ+2eFFzA=",
+ "requires": {
+ "es6-error": "^4.0.1"
+ }
+ },
+ "require-directory": {
+ "version": "2.1.1",
+ "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz",
+ "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I="
+ },
+ "require-main-filename": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz",
+ "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg=="
+ },
+ "require_optional": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/require_optional/-/require_optional-1.0.1.tgz",
+ "integrity": "sha512-qhM/y57enGWHAe3v/NcwML6a3/vfESLe/sGM2dII+gEO0BpKRUkWZow/tyloNqJyN6kXSl3RyyM8Ll5D/sJP8g==",
+ "requires": {
+ "resolve-from": "^2.0.0",
+ "semver": "^5.1.0"
+ },
+ "dependencies": {
+ "semver": {
+ "version": "5.7.1",
+ "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz",
+ "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ=="
+ }
+ }
+ },
+ "resolve": {
+ "version": "1.15.1",
+ "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.15.1.tgz",
+ "integrity": "sha512-84oo6ZTtoTUpjgNEr5SJyzQhzL72gaRodsSfyxC/AXRvwu0Yse9H8eF9IpGo7b8YetZhlI6v7ZQ6bKBFV/6S7w==",
+ "requires": {
+ "path-parse": "^1.0.6"
+ }
+ },
+ "resolve-from": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-2.0.0.tgz",
+ "integrity": "sha1-lICrIOlP+h2egKgEx+oUdhGWa1c="
+ },
+ "restore-cursor": {
+ "version": "3.1.0",
+ "resolved": "https://registry.npmjs.org/restore-cursor/-/restore-cursor-3.1.0.tgz",
+ "integrity": "sha512-l+sSefzHpj5qimhFSE5a8nufZYAM3sBSVMAPtYkmC+4EH2anSGaEMXSD0izRQbu9nfyQ9y5JrVmp7E8oZrUjvA==",
+ "dev": true,
+ "requires": {
+ "onetime": "^5.1.0",
+ "signal-exit": "^3.0.2"
+ }
+ },
+ "rimraf": {
+ "version": "3.0.2",
+ "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz",
+ "integrity": "sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==",
+ "requires": {
+ "glob": "^7.1.3"
+ }
+ },
+ "run-async": {
+ "version": "2.4.0",
+ "resolved": "https://registry.npmjs.org/run-async/-/run-async-2.4.0.tgz",
+ "integrity": "sha512-xJTbh/d7Lm7SBhc1tNvTpeCHaEzoyxPrqNlvSdMfBTYwaY++UJFyXUOxAtsRUXjlqOfj8luNaR9vjCh4KeV+pg==",
+ "dev": true,
+ "requires": {
+ "is-promise": "^2.1.0"
+ }
+ },
+ "rxjs": {
+ "version": "6.5.5",
+ "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-6.5.5.tgz",
+ "integrity": "sha512-WfQI+1gohdf0Dai/Bbmk5L5ItH5tYqm3ki2c5GdWhKjalzjg93N3avFjVStyZZz+A2Em+ZxKH5bNghw9UeylGQ==",
+ "dev": true,
+ "requires": {
+ "tslib": "^1.9.0"
+ }
+ },
+ "safe-buffer": {
+ "version": "5.1.2",
+ "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz",
+ "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g=="
+ },
+ "safer-buffer": {
+ "version": "2.1.2",
+ "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz",
+ "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg=="
+ },
+ "saslprep": {
+ "version": "1.0.3",
+ "resolved": "https://registry.npmjs.org/saslprep/-/saslprep-1.0.3.tgz",
+ "integrity": "sha512-/MY/PEMbk2SuY5sScONwhUDsV2p77Znkb/q3nSVstq/yQzYJOH/Azh29p9oJLsl3LnQwSvZDKagDGBsBwSooag==",
+ "optional": true,
+ "requires": {
+ "sparse-bitfield": "^3.0.3"
+ }
+ },
+ "sax": {
+ "version": "1.2.4",
+ "resolved": "https://registry.npmjs.org/sax/-/sax-1.2.4.tgz",
+ "integrity": "sha512-NqVDv9TpANUjFm0N8uM5GxL36UgKi9/atZw+x7YFnQ8ckwFGKrl4xX4yWtrey3UJm5nP1kUbnYgLopqWNSRhWw=="
+ },
+ "semver": {
+ "version": "6.3.0",
+ "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz",
+ "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw=="
+ },
+ "set-blocking": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz",
+ "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc="
+ },
+ "setimmediate": {
+ "version": "1.0.5",
+ "resolved": "https://registry.npmjs.org/setimmediate/-/setimmediate-1.0.5.tgz",
+ "integrity": "sha1-KQy7Iy4waULX1+qbg3Mqt4VvgoU="
+ },
+ "shebang-command": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz",
+ "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==",
+ "requires": {
+ "shebang-regex": "^3.0.0"
+ }
+ },
+ "shebang-regex": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz",
+ "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A=="
+ },
+ "sift": {
+ "version": "7.0.1",
+ "resolved": "https://registry.npmjs.org/sift/-/sift-7.0.1.tgz",
+ "integrity": "sha512-oqD7PMJ+uO6jV9EQCl0LrRw1OwsiPsiFQR5AR30heR+4Dl7jBBbDLnNvWiak20tzZlSE1H7RB30SX/1j/YYT7g=="
+ },
+ "signal-exit": {
+ "version": "3.0.3",
+ "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.3.tgz",
+ "integrity": "sha512-VUJ49FC8U1OxwZLxIbTTrDvLnf/6TDgxZcK8wxR8zs13xpx7xbG60ndBlhNrFi2EMuFRoeDoJO7wthSLq42EjA=="
+ },
+ "slice-ansi": {
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-2.1.0.tgz",
+ "integrity": "sha512-Qu+VC3EwYLldKa1fCxuuvULvSJOKEgk9pi8dZeCVK7TqBfUNTH4sFkk4joj8afVSfAYgJoSOetjx9QWOJ5mYoQ==",
+ "dev": true,
+ "requires": {
+ "ansi-styles": "^3.2.0",
+ "astral-regex": "^1.0.0",
+ "is-fullwidth-code-point": "^2.0.0"
+ },
+ "dependencies": {
+ "ansi-styles": {
+ "version": "3.2.1",
+ "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz",
+ "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==",
+ "dev": true,
+ "requires": {
+ "color-convert": "^1.9.0"
+ }
+ },
+ "color-convert": {
+ "version": "1.9.3",
+ "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz",
+ "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==",
+ "dev": true,
+ "requires": {
+ "color-name": "1.1.3"
+ }
+ },
+ "color-name": {
+ "version": "1.1.3",
+ "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz",
+ "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=",
+ "dev": true
+ },
+ "is-fullwidth-code-point": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz",
+ "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=",
+ "dev": true
+ }
+ }
+ },
+ "sliced": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/sliced/-/sliced-1.0.1.tgz",
+ "integrity": "sha1-CzpmK10Ewxd7GSa+qCsD+Dei70E="
+ },
+ "source-map": {
+ "version": "0.5.7",
+ "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz",
+ "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w="
+ },
+ "sparse-bitfield": {
+ "version": "3.0.3",
+ "resolved": "https://registry.npmjs.org/sparse-bitfield/-/sparse-bitfield-3.0.3.tgz",
+ "integrity": "sha1-/0rm5oZWBWuks+eSqzM004JzyhE=",
+ "optional": true,
+ "requires": {
+ "memory-pager": "^1.0.2"
+ }
+ },
+ "spawn-wrap": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/spawn-wrap/-/spawn-wrap-2.0.0.tgz",
+ "integrity": "sha512-EeajNjfN9zMnULLwhZZQU3GWBoFNkbngTUPfaawT4RkMiviTxcX0qfhVbGey39mfctfDHkWtuecgQ8NJcyQWHg==",
+ "requires": {
+ "foreground-child": "^2.0.0",
+ "is-windows": "^1.0.2",
+ "make-dir": "^3.0.0",
+ "rimraf": "^3.0.0",
+ "signal-exit": "^3.0.2",
+ "which": "^2.0.1"
+ }
+ },
+ "spdx-correct": {
+ "version": "3.1.0",
+ "resolved": "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.1.0.tgz",
+ "integrity": "sha512-lr2EZCctC2BNR7j7WzJ2FpDznxky1sjfxvvYEyzxNyb6lZXHODmEoJeFu4JupYlkfha1KZpJyoqiJ7pgA1qq8Q==",
+ "dev": true,
+ "requires": {
+ "spdx-expression-parse": "^3.0.0",
+ "spdx-license-ids": "^3.0.0"
+ }
+ },
+ "spdx-exceptions": {
+ "version": "2.2.0",
+ "resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.2.0.tgz",
+ "integrity": "sha512-2XQACfElKi9SlVb1CYadKDXvoajPgBVPn/gOQLrTvHdElaVhr7ZEbqJaRnJLVNeaI4cMEAgVCeBMKF6MWRDCRA==",
+ "dev": true
+ },
+ "spdx-expression-parse": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/spdx-expression-parse/-/spdx-expression-parse-3.0.0.tgz",
+ "integrity": "sha512-Yg6D3XpRD4kkOmTpdgbUiEJFKghJH03fiC1OPll5h/0sO6neh2jqRDVHOQ4o/LMea0tgCkbMgea5ip/e+MkWyg==",
+ "dev": true,
+ "requires": {
+ "spdx-exceptions": "^2.1.0",
+ "spdx-license-ids": "^3.0.0"
+ }
+ },
+ "spdx-license-ids": {
+ "version": "3.0.5",
+ "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.5.tgz",
+ "integrity": "sha512-J+FWzZoynJEXGphVIS+XEh3kFSjZX/1i9gFBaWQcB+/tmpe2qUsSBABpcxqxnAxFdiUFEgAX1bjYGQvIZmoz9Q==",
+ "dev": true
+ },
+ "sprintf-js": {
+ "version": "1.0.3",
+ "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz",
+ "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw="
+ },
+ "string-width": {
+ "version": "4.2.0",
+ "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.0.tgz",
+ "integrity": "sha512-zUz5JD+tgqtuDjMhwIg5uFVV3dtqZ9yQJlZVfq4I01/K5Paj5UHj7VyrQOJvzawSVlKpObApbfD0Ed6yJc+1eg==",
+ "requires": {
+ "emoji-regex": "^8.0.0",
+ "is-fullwidth-code-point": "^3.0.0",
+ "strip-ansi": "^6.0.0"
+ }
+ },
+ "string.prototype.trimend": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.0.tgz",
+ "integrity": "sha512-EEJnGqa/xNfIg05SxiPSqRS7S9qwDhYts1TSLR1BQfYUfPe1stofgGKvwERK9+9yf+PpfBMlpBaCHucXGPQfUA==",
+ "dev": true,
+ "requires": {
+ "define-properties": "^1.1.3",
+ "es-abstract": "^1.17.5"
+ }
+ },
+ "string.prototype.trimleft": {
+ "version": "2.1.2",
+ "resolved": "https://registry.npmjs.org/string.prototype.trimleft/-/string.prototype.trimleft-2.1.2.tgz",
+ "integrity": "sha512-gCA0tza1JBvqr3bfAIFJGqfdRTyPae82+KTnm3coDXkZN9wnuW3HjGgN386D7hfv5CHQYCI022/rJPVlqXyHSw==",
+ "dev": true,
+ "requires": {
+ "define-properties": "^1.1.3",
+ "es-abstract": "^1.17.5",
+ "string.prototype.trimstart": "^1.0.0"
+ }
+ },
+ "string.prototype.trimright": {
+ "version": "2.1.2",
+ "resolved": "https://registry.npmjs.org/string.prototype.trimright/-/string.prototype.trimright-2.1.2.tgz",
+ "integrity": "sha512-ZNRQ7sY3KroTaYjRS6EbNiiHrOkjihL9aQE/8gfQ4DtAC/aEBRHFJa44OmoWxGGqXuJlfKkZW4WcXErGr+9ZFg==",
+ "dev": true,
+ "requires": {
+ "define-properties": "^1.1.3",
+ "es-abstract": "^1.17.5",
+ "string.prototype.trimend": "^1.0.0"
+ }
+ },
+ "string.prototype.trimstart": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.0.tgz",
+ "integrity": "sha512-iCP8g01NFYiiBOnwG1Xc3WZLyoo+RuBymwIlWncShXDDJYWN6DbnM3odslBJdgCdRlq94B5s63NWAZlcn2CS4w==",
+ "dev": true,
+ "requires": {
+ "define-properties": "^1.1.3",
+ "es-abstract": "^1.17.5"
+ }
+ },
+ "string_decoder": {
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz",
+ "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==",
+ "requires": {
+ "safe-buffer": "~5.1.0"
+ }
+ },
+ "strip-ansi": {
+ "version": "6.0.0",
+ "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz",
+ "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==",
+ "requires": {
+ "ansi-regex": "^5.0.0"
+ }
+ },
+ "strip-bom": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-4.0.0.tgz",
+ "integrity": "sha512-3xurFv5tEgii33Zi8Jtp55wEIILR9eh34FAW00PZf+JnSsTmV/ioewSgQl97JHvgjoRGwPShsWm+IdrxB35d0w=="
+ },
+ "strip-json-comments": {
+ "version": "3.0.1",
+ "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.0.1.tgz",
+ "integrity": "sha512-VTyMAUfdm047mwKl+u79WIdrZxtFtn+nBxHeb844XBQ9uMNTuTHdx2hc5RiAJYqwTj3wc/xe5HLSdJSkJ+WfZw==",
+ "dev": true
+ },
+ "supports-color": {
+ "version": "7.1.0",
+ "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz",
+ "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==",
+ "requires": {
+ "has-flag": "^4.0.0"
+ }
+ },
+ "table": {
+ "version": "5.4.6",
+ "resolved": "https://registry.npmjs.org/table/-/table-5.4.6.tgz",
+ "integrity": "sha512-wmEc8m4fjnob4gt5riFRtTu/6+4rSe12TpAELNSqHMfF3IqnA+CH37USM6/YR3qRZv7e56kAEAtd6nKZaxe0Ug==",
+ "dev": true,
+ "requires": {
+ "ajv": "^6.10.2",
+ "lodash": "^4.17.14",
+ "slice-ansi": "^2.1.0",
+ "string-width": "^3.0.0"
+ },
+ "dependencies": {
+ "ajv": {
+ "version": "6.12.0",
+ "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.0.tgz",
+ "integrity": "sha512-D6gFiFA0RRLyUbvijN74DWAjXSFxWKaWP7mldxkVhyhAV3+SWA9HEJPHQ2c9soIeTFJqcSdFDGFgdqs1iUU2Hw==",
+ "dev": true,
+ "requires": {
+ "fast-deep-equal": "^3.1.1",
+ "fast-json-stable-stringify": "^2.0.0",
+ "json-schema-traverse": "^0.4.1",
+ "uri-js": "^4.2.2"
+ }
+ },
+ "ansi-regex": {
+ "version": "4.1.0",
+ "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz",
+ "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==",
+ "dev": true
+ },
+ "emoji-regex": {
+ "version": "7.0.3",
+ "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz",
+ "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==",
+ "dev": true
+ },
+ "is-fullwidth-code-point": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz",
+ "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=",
+ "dev": true
+ },
+ "string-width": {
+ "version": "3.1.0",
+ "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz",
+ "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==",
+ "dev": true,
+ "requires": {
+ "emoji-regex": "^7.0.1",
+ "is-fullwidth-code-point": "^2.0.0",
+ "strip-ansi": "^5.1.0"
+ }
+ },
+ "strip-ansi": {
+ "version": "5.2.0",
+ "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz",
+ "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==",
+ "dev": true,
+ "requires": {
+ "ansi-regex": "^4.1.0"
+ }
+ }
+ }
+ },
+ "tar": {
+ "version": "4.4.13",
+ "resolved": "https://registry.npmjs.org/tar/-/tar-4.4.13.tgz",
+ "integrity": "sha512-w2VwSrBoHa5BsSyH+KxEqeQBAllHhccyMFVHtGtdMpF4W7IRWfZjFiQceJPChOeTsSDVUpER2T8FA93pr0L+QA==",
+ "requires": {
+ "chownr": "^1.1.1",
+ "fs-minipass": "^1.2.5",
+ "minipass": "^2.8.6",
+ "minizlib": "^1.2.1",
+ "mkdirp": "^0.5.0",
+ "safe-buffer": "^5.1.2",
+ "yallist": "^3.0.3"
+ }
+ },
+ "test-exclude": {
+ "version": "6.0.0",
+ "resolved": "https://registry.npmjs.org/test-exclude/-/test-exclude-6.0.0.tgz",
+ "integrity": "sha512-cAGWPIyOHU6zlmg88jwm7VRyXnMN7iV68OGAbYDk/Mh/xC/pzVPlQtY6ngoIH/5/tciuhGfvESU8GrHrcxD56w==",
+ "requires": {
+ "@istanbuljs/schema": "^0.1.2",
+ "glob": "^7.1.4",
+ "minimatch": "^3.0.4"
+ }
+ },
+ "text-table": {
+ "version": "0.2.0",
+ "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz",
+ "integrity": "sha1-f17oI66AUgfACvLfSoTsP8+lcLQ=",
+ "dev": true
+ },
+ "through": {
+ "version": "2.3.8",
+ "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz",
+ "integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=",
+ "dev": true
+ },
+ "tinytim": {
+ "version": "0.1.1",
+ "resolved": "https://registry.npmjs.org/tinytim/-/tinytim-0.1.1.tgz",
+ "integrity": "sha1-yWih5VWa2VUyJO92J7qzTjyu+Kg="
+ },
+ "tmp": {
+ "version": "0.0.33",
+ "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.0.33.tgz",
+ "integrity": "sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw==",
+ "dev": true,
+ "requires": {
+ "os-tmpdir": "~1.0.2"
+ }
+ },
+ "to-fast-properties": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz",
+ "integrity": "sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4="
+ },
+ "tracer": {
+ "version": "1.0.3",
+ "resolved": "https://registry.npmjs.org/tracer/-/tracer-1.0.3.tgz",
+ "integrity": "sha512-cP1wzE0eCzDrp6wMGG9Cg927qBPY18rPVMJ0BEjifHn5xVb7fbQDT5zjwItAyebUgF8hGY1N4VyI3hArGjffww==",
+ "requires": {
+ "colors": "1.4.0",
+ "dateformat": "3.0.3",
+ "mkdirp": "^1.0.4",
+ "nyc": "^15.0.1",
+ "tinytim": "0.1.1"
+ },
+ "dependencies": {
+ "mkdirp": {
+ "version": "1.0.4",
+ "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz",
+ "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw=="
+ }
+ }
+ },
+ "tslib": {
+ "version": "1.11.1",
+ "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.11.1.tgz",
+ "integrity": "sha512-aZW88SY8kQbU7gpV19lN24LtXh/yD4ZZg6qieAJDDg+YBsJcSmLGK9QpnUjAKVG/xefmvJGd1WUmfpT/g6AJGA=="
+ },
+ "tweetnacl": {
+ "version": "1.0.3",
+ "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-1.0.3.tgz",
+ "integrity": "sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw=="
+ },
+ "type-check": {
+ "version": "0.3.2",
+ "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.3.2.tgz",
+ "integrity": "sha1-WITKtRLPHTVeP7eE8wgEsrUg23I=",
+ "dev": true,
+ "requires": {
+ "prelude-ls": "~1.1.2"
+ }
+ },
+ "type-fest": {
+ "version": "0.8.1",
+ "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.8.1.tgz",
+ "integrity": "sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA=="
+ },
+ "typedarray-to-buffer": {
+ "version": "3.1.5",
+ "resolved": "https://registry.npmjs.org/typedarray-to-buffer/-/typedarray-to-buffer-3.1.5.tgz",
+ "integrity": "sha512-zdu8XMNEDepKKR+XYOXAVPtWui0ly0NtohUscw+UmaHiAWT8hrV1rr//H6V+0DvJ3OQ19S979M0laLfX8rm82Q==",
+ "requires": {
+ "is-typedarray": "^1.0.0"
+ }
+ },
+ "uri-js": {
+ "version": "4.2.2",
+ "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz",
+ "integrity": "sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ==",
+ "dev": true,
+ "requires": {
+ "punycode": "^2.1.0"
+ },
+ "dependencies": {
+ "punycode": {
+ "version": "2.1.1",
+ "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz",
+ "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==",
+ "dev": true
+ }
+ }
+ },
+ "util-deprecate": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz",
+ "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8="
+ },
+ "uuid": {
+ "version": "3.4.0",
+ "resolved": "https://registry.npmjs.org/uuid/-/uuid-3.4.0.tgz",
+ "integrity": "sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A=="
+ },
+ "v8-compile-cache": {
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/v8-compile-cache/-/v8-compile-cache-2.1.0.tgz",
+ "integrity": "sha512-usZBT3PW+LOjM25wbqIlZwPeJV+3OSz3M1k1Ws8snlW39dZyYL9lOGC5FgPVHfk0jKmjiDV8Z0mIbVQPiwFs7g==",
+ "dev": true
+ },
+ "validate-npm-package-license": {
+ "version": "3.0.4",
+ "resolved": "https://registry.npmjs.org/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz",
+ "integrity": "sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==",
+ "dev": true,
+ "requires": {
+ "spdx-correct": "^3.0.0",
+ "spdx-expression-parse": "^3.0.0"
+ }
+ },
+ "which": {
+ "version": "2.0.2",
+ "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz",
+ "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==",
+ "requires": {
+ "isexe": "^2.0.0"
+ }
+ },
+ "which-module": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz",
+ "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho="
+ },
+ "wide-align": {
+ "version": "1.1.3",
+ "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.3.tgz",
+ "integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==",
+ "requires": {
+ "string-width": "^1.0.2 || 2"
+ },
+ "dependencies": {
+ "ansi-regex": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz",
+ "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg="
+ },
+ "is-fullwidth-code-point": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz",
+ "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8="
+ },
+ "string-width": {
+ "version": "2.1.1",
+ "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz",
+ "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==",
+ "requires": {
+ "is-fullwidth-code-point": "^2.0.0",
+ "strip-ansi": "^4.0.0"
+ }
+ },
+ "strip-ansi": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz",
+ "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=",
+ "requires": {
+ "ansi-regex": "^3.0.0"
+ }
+ }
+ }
+ },
+ "word-wrap": {
+ "version": "1.2.3",
+ "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.3.tgz",
+ "integrity": "sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ==",
+ "dev": true
+ },
+ "wrap-ansi": {
+ "version": "6.2.0",
+ "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-6.2.0.tgz",
+ "integrity": "sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA==",
+ "requires": {
+ "ansi-styles": "^4.0.0",
+ "string-width": "^4.1.0",
+ "strip-ansi": "^6.0.0"
+ }
+ },
+ "wrappy": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz",
+ "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8="
+ },
+ "write": {
+ "version": "1.0.3",
+ "resolved": "https://registry.npmjs.org/write/-/write-1.0.3.tgz",
+ "integrity": "sha512-/lg70HAjtkUgWPVZhZcm+T4hkL8Zbtp1nFNOn3lRrxnlv50SRBv7cR7RqR+GMsd3hUXy9hWBo4CHTbFTcOYwig==",
+ "dev": true,
+ "requires": {
+ "mkdirp": "^0.5.1"
+ }
+ },
+ "write-file-atomic": {
+ "version": "3.0.3",
+ "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-3.0.3.tgz",
+ "integrity": "sha512-AvHcyZ5JnSfq3ioSyjrBkH9yW4m7Ayk8/9My/DD9onKeu/94fwrMocemO2QAJFAlnnDN+ZDS+ZjAR5ua1/PV/Q==",
+ "requires": {
+ "imurmurhash": "^0.1.4",
+ "is-typedarray": "^1.0.0",
+ "signal-exit": "^3.0.2",
+ "typedarray-to-buffer": "^3.1.5"
+ }
+ },
+ "ws": {
+ "version": "7.2.3",
+ "resolved": "https://registry.npmjs.org/ws/-/ws-7.2.3.tgz",
+ "integrity": "sha512-HTDl9G9hbkNDk98naoR/cHDws7+EyYMOdL1BmjsZXRUjf7d+MficC4B7HLUPlSiho0vg+CWKrGIt/VJBd1xunQ=="
+ },
+ "y18n": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz",
+ "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w=="
+ },
+ "yallist": {
+ "version": "3.1.1",
+ "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz",
+ "integrity": "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g=="
+ },
+ "yargs": {
+ "version": "15.3.1",
+ "resolved": "https://registry.npmjs.org/yargs/-/yargs-15.3.1.tgz",
+ "integrity": "sha512-92O1HWEjw27sBfgmXiixJWT5hRBp2eobqXicLtPBIDBhYB+1HpwZlXmbW2luivBJHBzki+7VyCLRtAkScbTBQA==",
+ "requires": {
+ "cliui": "^6.0.0",
+ "decamelize": "^1.2.0",
+ "find-up": "^4.1.0",
+ "get-caller-file": "^2.0.1",
+ "require-directory": "^2.1.1",
+ "require-main-filename": "^2.0.0",
+ "set-blocking": "^2.0.0",
+ "string-width": "^4.2.0",
+ "which-module": "^2.0.0",
+ "y18n": "^4.0.0",
+ "yargs-parser": "^18.1.1"
+ }
+ },
+ "yargs-parser": {
+ "version": "18.1.3",
+ "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-18.1.3.tgz",
+ "integrity": "sha512-o50j0JeToy/4K6OZcaQmW6lyXXKhq7csREXcDwk2omFPJEwUNOVtJKvmDr9EI1fAJZUyZcRF7kxGBWmRXudrCQ==",
+ "requires": {
+ "camelcase": "^5.0.0",
+ "decamelize": "^1.2.0"
+ }
+ },
+ "ytdl-core": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/ytdl-core/-/ytdl-core-2.0.1.tgz",
+ "integrity": "sha512-PZBcVzQpkBxi9OQh9I4QIrYNmkbM/zh4QJQuxE8I6RojLUVYkkps5iLYquE3H+pwmBXtEXQMDJfVRajgdiz+iA==",
+ "requires": {
+ "html-entities": "^1.1.3",
+ "m3u8stream": "^0.6.3",
+ "miniget": "^1.7.0",
+ "sax": "^1.1.3"
+ }
+ },
+ "ytdl-core-discord": {
+ "version": "1.2.0",
+ "resolved": "https://registry.npmjs.org/ytdl-core-discord/-/ytdl-core-discord-1.2.0.tgz",
+ "integrity": "sha512-BTE0eslSZzovThOAXbT9KZjsh2spu9y0nl9ZNrGNn4rLip8xocmYpDUEN8X03tTcGUybpzyN8J7wwM2/gNLRiA==",
+ "requires": {
+ "@types/node": "^13.11.1",
+ "prism-media": "^1.2.1",
+ "ytdl-core": "^2.0.1"
+ }
+ }
+ }
+}
diff --git a/package.json b/package.json
index 891ab34..b31d1e8 100644
--- a/package.json
+++ b/package.json
@@ -1,34 +1,30 @@
{
"name": "woomy",
- "version": "1.1.0",
- "description": "Woomy is a all-purpose discord bot built off the guidebot base and coded in node.js using discord.js.",
+ "version": "2.0.0",
+ "description": "uwu",
"main": "index.js",
"dependencies": {
"@discordjs/opus": "^0.1.0",
- "better-sqlite3": "^5.4.1",
- "chalk": "^3.0.0",
- "dblapi.js": "^2.3.1",
- "discord.js": "^12.0.2",
- "enmap": "^5.2.4",
- "garfield": "^1.1.2",
- "get-youtube-id": "^1.0.1",
+ "@sentry/node": "^5.15.4",
+ "colors": "^1.4.0",
+ "discord.js": "^12.2.0",
"hastebin-gen": "^2.0.5",
+ "is-docker": "^2.0.0",
"moment": "^2.24.0",
- "moment-duration-format": "^2.3.2",
- "nekos.life": "^2.0.5",
+ "mongoose": "^5.9.9",
"node-fetch": "^2.6.0",
- "openweather-apis": "^4.2.0",
"prism-media": "^1.2.1",
- "randomcolor": "^0.5.4",
- "relevant-urban": "^2.0.0",
- "request": "^2.88.2",
- "to-zalgo": "^1.0.1",
- "urban": "^0.3.2",
- "weather-js": "^2.0.0",
- "youtube-info": "^1.3.2",
- "ytdl-core-discord": "^1.1.0"
+ "tracer": "^1.0.3",
+ "ytdl-core-discord": "^1.2.0"
+ },
+ "devDependencies": {
+ "eslint": "^6.8.0",
+ "eslint-config-standard": "^14.1.1",
+ "eslint-plugin-import": "^2.20.2",
+ "eslint-plugin-node": "^11.1.0",
+ "eslint-plugin-promise": "^4.2.1",
+ "eslint-plugin-standard": "^4.0.1"
},
- "devDependencies": {},
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
@@ -37,7 +33,7 @@
"url": "git+https://github.com/mudkipscience/woomy.git"
},
"author": "mudkipscience",
- "license": "MIT",
+ "license": "GPL-3.0",
"bugs": {
"url": "https://github.com/mudkipscience/woomy/issues"
},
diff --git a/resources/other/coolpeople.json b/resources/other/coolpeople.json
deleted file mode 100644
index d5f335c..0000000
--- a/resources/other/coolpeople.json
+++ /dev/null
@@ -1,21 +0,0 @@
-{
- "coolPeople": [
- "448354605617643520",
- "433790467830972417",
- "231777839576252417",
- "285992938314661899",
- "231704701433937931",
- "324937993972350976",
- "336492042299637771",
- "273867501006225419",
- "331870539897372672",
- "304000458144481280",
- "239787232666451980",
- "264970229514371072",
- "254310746450690048",
- "358390849807319040",
- "211011138656272386",
- "266472557740425216",
- "102943767346057216"
- ]
-}
\ No newline at end of file
diff --git a/resources/other/sexualities.json b/resources/other/sexualities.json
deleted file mode 100644
index a8805ed..0000000
--- a/resources/other/sexualities.json
+++ /dev/null
@@ -1,102 +0,0 @@
-{
- "aesthetic attraction": {
- "name": "aesthetic attraction",
- "description": "Getting pleasure from the appearance of a specific individual like you would from watching beautiful scenery."
- },
- "platonic attraction": {
- "name": "platonic attraction",
- "description": "A desire to have a platonic relationship or friendship with a specific individual."
- },
- "romantic attraction": {
- "name": "romantic attraction",
- "description": "A desire to have a romantic relationship with a specific individual."
- },
- "sensual attraction": {
- "name": "sensual attraction",
- "description": "A desire for physical intimacy with a specific individual. Cuddling, hand holding, etc."
- },
- "sexual attraction": {
- "name": "sexual attraction",
- "description": "A desire for sexual contact with a specific individual."
- },
- "abrosexual": {
- "name": "abrosexual",
- "description": "Someone whose sexuality changes frequently. They experience different sexualities over time."
- },
- "androgynosexual": {
- "name": "androgynosexual",
- "description": "Someone who is attracted to both men and women, particularly those who are androgynous in appearance."
- },
- "androsexual": {
- "name": "androsexual",
- "description": "Someone who is attracted to men and/or masculine people."
- },
- "aromantic": {
- "name": "aromantic",
- "description": "Someone who does not experience romantic attraction. They do not have to also be asexual however as they may still experience other types of attraction."
- },
- "asexual": {
- "name": "asexual",
- "description": "Someone who feels little to no sexual attraction to anyone."
- },
- "bisexual": {
- "name": "bisexual",
- "description": "Someone who is attracted to more than one gender."
- },
- "ceterosexual": {
- "name": "ceterosexual",
- "description": "Someone who is attracted to non-binary people."
- },
- "demisexual": {
- "name": "demisexual",
- "description": "Someone who doesn't experience sexual/romantic attraction towards someone until they form an emotional connection."
- },
- "finsexual": {
- "name": "finsexual",
- "description": "Someone who is attracted to women and/or feminine people."
- },
- "gay": {
- "name": "gay",
- "description": "Someone who is homosexual (attracted to ones own gender)"
- },
- "gynosexual": {
- "name": "gynosexual",
- "description": "Someone who as attracted to women and/or feminity."
- },
- "grey-romantic": {
- "name": "grey-romantic",
- "description": "Someone with a romantic orentiation that is somewhere between aromantic and romantic."
- },
- "heterosexual": {
- "name": "heterosexual",
- "description": "Someone who is attracted to people of the opposite gender."
- },
- "homosexual": {
- "name": "homosexual",
- "description": "Someone attracted to people of ones own gender."
- },
- "lesbian": {
- "name": "lesbian",
- "description": "A woman who is attracted to other women."
- },
- "omnisexual": {
- "name": "omnisexual",
- "description": "Someone who is attracted to all genders."
- },
- "pansexual": {
- "name": "pansexual",
- "description": "Someone who is attracted towards people regardless of their gender identity."
- },
- "pomosexual": {
- "name": "pomosexual",
- "description": "Someone who does not fit into any sexual orientation label."
- },
- "polysexual": {
- "name": "polysexual",
- "description": "Someone who is attracted to some, but not all genders."
- },
- "straight": {
- "name": "straight",
- "description": "Someone who is heterosexual (attracted to people of the opposite gender)"
- }
-}
\ No newline at end of file
diff --git a/src/commands/8ball.js b/src/commands/8ball.js
deleted file mode 100644
index ef69684..0000000
--- a/src/commands/8ball.js
+++ /dev/null
@@ -1,38 +0,0 @@
-exports.run = async (client, message, args) => {
- if (!args[0])
- return message.channel.send(
- `<:error:466995152976871434> You did not ask me a question. Usage: \`${client.commands.get(`8ball`).help.usage}\``
- );
-
- var ball = [
- "No darndested clue.",
- "Stupid question. You should be ashamed of yourself for even asking.",
- "Yes!",
- "Not in your wildest dreams!",
- "No chance.",
- "Never.",
- "Just Google it.",
- "¯\\_(ツ)_/¯",
- "Possibly.",
- "There's a high chance.",
- "I'd rather not say."
- ];
-
- let mess = ball.random();
- message.channel.send(":8ball: " + mess);
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "8ball",
- category: "Fun",
- description: "Consult the 8ball for advice.",
- usage: "8ball [question]"
-};
diff --git a/src/commands/about.js b/src/commands/about.js
deleted file mode 100644
index 2049bfa..0000000
--- a/src/commands/about.js
+++ /dev/null
@@ -1,58 +0,0 @@
-
-const { version } = require("discord.js");
-const moment = require("moment");
-require("moment-duration-format");
-
-exports.run = (client, message) => {
- const duration = moment
- .duration(client.uptime)
- .format(" D [days], H [hrs], m [mins], s [secs]");
-
- var mud = client.users.cache.get(client.config.owners[0]).tag;
- var flgx = client.users.cache.get(client.config.owners[1]).tag;
- var build;
- var prefix;
-
- if(message.guild) {
- prefix = message.settings.prefix;
- } else {
- prefix = client.config.defaultSettings.prefix;
- };
-
- if(client.devmode == true) {
- build = "development"
- } else {
- build = "production"
- }
-
- embed = new Discord.MessageEmbed();
- embed.setColor(client.embedColour(message));
- embed.setThumbnail(client.user.avatarURL({format: "png", dynamic: true, size: 2048}))
- embed.setTitle("About Woomy")
- embed.addField(
- "General:", `• users: \`${client.users.cache.size}\`\n• channels: \`${client.channels.cache.size}\`\n• servers: \`${client.guilds.cache.size}\`\n• commands: \`${client.commands.size}\`\n• uptime: \`${duration}\``,true
- );
- embed.addField(
- `Technical:`, `• RAM Usage: \`${(process.memoryUsage().heapUsed / 1024 / 1024).toFixed(2)} MB\`\n• OS: \`${require("os").type}\`\n• bot version: \`${client.version.number} (${build})\`\n• discord.js version: \`v${version}\`\n• node.js version: \`${process.version}\``,true
- );
- embed.addField(
- "Links:", "[Support](https://discord.gg/HCF8mdv) | [GitHub](https://github.com/mudkipscience/woomy) | [db.org](https://discordbots.org/bot/435961704145485835/vote) | [BFD](https://botsfordiscord.com/bots/435961704145485835/vote) | [top.gg](https://discordbotlist.com/bots/435961704145485835) | [discord.js](https://discord.js.org/#/) | [guidebot](https://github.com/AnIdiotsGuide/guidebot/)"
- );
-
- message.channel.send(embed);
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["stats", "botinfo"],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "about",
- category: "Utility",
- description: "Information about the bot, as well as a couple of helpful links",
- usage: "about"
-};
diff --git a/src/commands/achievement.js b/src/commands/achievement.js
deleted file mode 100644
index 49b75f7..0000000
--- a/src/commands/achievement.js
+++ /dev/null
@@ -1,41 +0,0 @@
-Discord = require("discord.js");
-
-const url = "https://www.minecraftskinstealer.com/achievement/a.php";
-
-exports.run = (client, message, args) => {
- let text = args.join(" ");
-
- if (!text) {
- return message.channel.send(
- `<:error:466995152976871434> No text provided to turn into an achievement. Usage: \`${client.commands.get(`achievement`).help.usage}\``
- );
- };
- message.channel.startTyping();
- let params = "h=Achievement+Get%21&i=1&t=" + encodeURIComponent(text);
-
- try {
- message.channel.stopTyping();
- message.channel.send({
- files: [new Discord.MessageAttachment(url + "?" + params, "achievement.png")]
- });
-
- } catch(err) {
- message.channel.stopTyping();
- message.channel.send(`<:error:466995152976871434> Error when generating image: \`${err}\``)
- }
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: ["ATTACH_FILES"]
-};
-
-exports.help = {
- name: "achievement",
- category: "Fun",
- description: "Generates an minecraft achievement.",
- usage: "achievement [text]"
-};
diff --git a/src/commands/activity.js b/src/commands/activity.js
deleted file mode 100644
index 59ab78a..0000000
--- a/src/commands/activity.js
+++ /dev/null
@@ -1,45 +0,0 @@
-exports.run = (client, message, args) => {
- if(!args[0]) {
- return message.channel.send(`<:error:466995152976871434> No arguments! Usage: \`${client.commands.get(`activity`).help.usage}\``)
- }
- if(client.lockActivity == true) {
- activityLocked = "locked";
- } else {
- activityLocked = "unlocked";
- }
-
- if(args[0] == "lock" && !args[1]) {
- client.lockActivity = true;
- return message.channel.send(
- "<:success:466995111885144095> Activity has been locked will no longer change automatically."
- );
- };
-
- if(args[0] == "unlock" && !args[1]) {
- client.lockActivity = false;
- return message.channel.send(
- "<:success:466995111885144095> Activity has been unlocked and will begin changing automatically."
- );
- };
-
- client.lockActivity = true;
- client.user.setActivity(args.join(" "));
- message.channel.send(
- `<:success:466995111885144095> Activity locked and changed to \`${args.join(" ")}\`
- `);
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "Developer",
- requiredPerms: []
-};
-
-exports.help = {
- name: "activity",
- category: "Owner",
- description: "Changes the bot's activity and disables automatic changing of the activity",
- usage: "activity [activity] **OR** activity [lock/unlock]"
-};
diff --git a/src/commands/adminrole.js b/src/commands/adminrole.js
deleted file mode 100644
index 6e3d231..0000000
--- a/src/commands/adminrole.js
+++ /dev/null
@@ -1,61 +0,0 @@
-exports.run = async (client, message, args) => {
-
- const settings = message.settings;
-
- if (!client.settings.has(message.guild.id)) {
- client.settings.set(message.guild.id, {});
- }
-
- var adminRole = message.guild.roles.cache.get(settings.adminRole)
-
- if (!args[0]) {
- if(!adminRole) {
- return message.channel.send(
- `<:error:466995152976871434> There is no admin role set for this server. Please set one using \`${message.settings.prefix}adminrole \``
- );
- } else {
- message.channel.send(`The current admin role is: \`${adminRole.name}\``)
- }
-
- } else {
- const joinedValue = args.join(" ");
- if (joinedValue.length < 1) {
- return message.channel.send(
- `<:error:466995152976871434> You didn't specify a role. Usage: \`${client.commands.get(`adminrole`).help.usage}\``
- );
- };
-
- if (settings.adminRole != "None set" && joinedValue === adminRole.name) {
- return message.channel.send(
- "<:error:466995152976871434> The admin role is already set to that!"
- );
- };
-
- let role = client.findRole(joinedValue, message);
-
- if (!role) {
- return message.channel.send(`<:error:466995152976871434> That role doesn't seem to exist. Try again!`);
- };
-
- client.settings.set(message.guild.id, role.id, "adminRole");
-
- message.channel.send(
- `<:success:466995111885144095> The admin role has been set to \`${role.name}\`
- `);
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Server Owner",
- requiredPerms: []
-};
-
-exports.help = {
- name: "adminrole",
- category: "Configure",
- description: "Sets the admin role for this server.",
- usage: "adminrole [role]"
-};
diff --git a/src/commands/autorole.js b/src/commands/autorole.js
deleted file mode 100644
index 2aae88d..0000000
--- a/src/commands/autorole.js
+++ /dev/null
@@ -1,69 +0,0 @@
-exports.run = async (client, message, args) => {
-
- const settings = message.settings;
-
- if (!client.settings.has(message.guild.id)) {
- client.settings.set(message.guild.id, {});
- }
-
- var autorole = message.guild.roles.cache.get(settings.autorole)
-
- if (!args[0]) {
- if(!autorole) {
- return message.channel.send(
- `<:error:466995152976871434> There is no autorole set for this server. Please set one using \`${message.settings.prefix}autorole \``
- );
- } else {
- message.channel.send(`Users recieve this role upon joining: \`${autorole.name}\``)
- }
-
- } else if(args.join(" ").toLowerCase() == "off") {
- if(settings.autorole == "off") {
- return message.channel.send("<:error:466995152976871434> Autoroling has not been enabled.")
- }
-
- client.settings.set(message.guild.id, "off", "autorole");
- return message.channel.send("<:success:466995111885144095> Autoroling has been disabled.")
- } else {
-
- const joinedValue = args.join(" ");
- if (joinedValue.length < 1) {
- return message.channel.send(
- `<:error:466995152976871434> You didn't specify a role. Usage: \`${client.commands.get(`autorole`).help.usage}\``
- );
- };
-
- if (settings.autorole != "off" && joinedValue === autorole.name) {
- return message.channel.send(
- "<:error:466995152976871434> The autorole is already set to that!"
- );
- };
-
- role = client.findRole(joinedValue, message);
-
- if (!role) {
- return message.channel.send(`<:error:466995152976871434> That role doesn't seem to exist. Try again!`);
- };
-
- client.settings.set(message.guild.id, role.id, "autorole");
-
- message.channel.send(
- `<:success:466995111885144095> The autorole has been set to \`${role.name}\`
- `);
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Administrator",
- requiredPerms: ["MANAGE_ROLES"]
-};
-
-exports.help = {
- name: "autorole",
- category: "Configure",
- description: "Sets the autorole for this server.",
- usage: "autorole **OR** autorole off"
-};
diff --git a/src/commands/avatar.js b/src/commands/avatar.js
deleted file mode 100644
index 5832be2..0000000
--- a/src/commands/avatar.js
+++ /dev/null
@@ -1,38 +0,0 @@
-exports.run = (client, message, args) => {
- let user = message.mentions.users.first();
- let users;
- if (!args[0] || !message.guild) {
- user = message.author;
- };
-
- if (!user && message.guild) {
- users = client.searchForMembers(message.guild, args[0]);
- if (users.length > 1) {
- return message.channel.send(
- "<:error:466995152976871434> Found multiple users, please be more specific or mention the user instead."
- );
- } else if (users.length == 0) {
- return message.channel.send(
- "<:error:466995152976871434> That user doesn't seem to exist, try again!"
- );
- };
- user = users[0];
- user = user.user;
- }
- message.channel.send(`**${user.tag}'s** avatar is: ${user.avatarURL({format: "png", dynamic: true, size: 2048})}`);
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "avatar",
- category: "Utility",
- description: "Gives you the specified users avatar.",
- usage: "avatar "
-};
diff --git a/src/commands/ban.js b/src/commands/ban.js
deleted file mode 100644
index affa882..0000000
--- a/src/commands/ban.js
+++ /dev/null
@@ -1,87 +0,0 @@
-exports.run = async (client, message, args) => {
- const settings = (message.settings = client.getSettings(message.guild.id));
-
- if(!args[0]) {
- return message.channel.send(
- `<:error:466995152976871434> No username provided. Usage: \`${client.commands.get(`ban`).help.usage}\``
- );
- };
-
- let user = message.mentions.members.first();
-
- if (!user) {
- let users;
- users = client.searchForMembers(message.guild, args[0]);
- if (users.length > 1)
- return message.channel.send(
- "<:error:466995152976871434> Found multiple users! Please be more specific or mention the user instead."
- );
- else if (users.length == 0)
- return message.channel.send(
- "<:error:466995152976871434> That user doesn't seem to exist. Try again!"
- );
- user = users[0];
- };
-
- if (user.user.id === message.guild.owner.id) {
- return message.channel.send("<:error:466995152976871434> You can't ban the owner!")
- };
- let moderator = message.guild.member(message.author)
- if (user.roles.highest.position >= moderator.roles.highest.position && moderator.user.id !== message.guild.ownerID) {
- return message.channel.send(
- `<:error:466995152976871434> You can't ban people higher ranked than yourself!`
- );
- };
-
- let bot = message.guild.member(client.user)
- if (user.roles.highest.position >= bot.roles.highest.position) {
- return message.channel.send(
- `<:error:466995152976871434> I can't ban people who are higher ranked than me!`
- );
- };
-
- if (!user.bannable)
- return message.channel.send(
- "<:error:466995152976871434> Specified user is not bannable."
- );
-
- let reason = args.slice(1).join(" ");
- if (!reason) reason = `Banned by ${message.author.tag}`;
- await message.guild.members.ban(user, {reason: reason}).catch(console.error);
- message.channel.send(`<:success:466995111885144095> Banned \`${user.user.tag}\``);
-
- if (settings.modlogsChannel !== "off") {
- const channel = message.guild.channels.cache.find(
- channel => channel.name === settings.modlogsChannel
- );
-
- if (channel) {
- let embed = new Discord.MessageEmbed();
- embed.setColor("#BC0057");
- embed.setAuthor("User banned!", user.user.avatarURL({format: "png", dynamic: true, size: 2048}));
- embed.setDescription(
- `• User: ${user.user.tag} (${user.user.id})\n• Mod: ${message.author} (${message.author.id})\n• Reason: ${reason}`
- );
- try {
- channel.send(embed);
- } catch (err) {
- // probably no permissions to send messages/embeds there
- };
- };
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Moderator",
- requiredPerms: ["BAN_MEMBERS"]
-};
-
-exports.help = {
- name: "ban",
- category: "Moderation",
- description: "Bans specified user.",
- usage: "ban [user] "
-};
diff --git a/src/commands/blacklist.js b/src/commands/blacklist.js
deleted file mode 100644
index 20c41aa..0000000
--- a/src/commands/blacklist.js
+++ /dev/null
@@ -1,124 +0,0 @@
-exports.run = async (client, message, [action, ...member]) => {
- const settings = message.settings;
-
- if(settings.blacklisted == "ARRAY") {
- await client.settings.set(message.guild.id, [], "blacklisted");
- }
-
- if(!action) {
- return message.channel.send(
- `<:error:466995152976871434> You didn't tell me if I was meant to add or remove someone from the blacklist! Usage: \`${client.commands.get(`blacklist`).help.usage}\``
- )
- }
-
- member = member.join(" ")
-
- if(!member) {
- return message.channel.send(
- `<:error:466995152976871434> You didn't tell me who to blacklist! Usage: \`${client.commands.get(`blacklist`).help.usage}\``
- );
- };
-
- let user = message.mentions.members.first();
-
- if(action == "add") {
- if (!user) {
- let users;
- users = client.searchForMembers(message.guild, member);
- if (users.length > 1)
- return message.channel.send(
- "<:error:466995152976871434> Found multiple users! Please be more specific or mention the user instead."
- );
- else if (users.length == 0)
- return message.channel.send(
- "<:error:466995152976871434> That user doesn't seem to exist. Try again!"
- );
- user = users[0];
- };
-
- if(user.id === client.user.id) {
- return message.channel.send('lol no');
- };
-
- if (user.id === message.guild.owner.id) {
- return message.channel.send("<:error:466995152976871434> You can't blacklist the owner!")
- };
-
- let admin = message.guild.member(message.author)
- if (user.roles.highest.position >= admin.roles.highest.position && admin.user.id !== message.guild.ownerID) {
- return message.channel.send(
- `<:error:466995152976871434> You can't blacklist people higher ranked than yourself!`
- );
- };
-
- if(user.id === message.member.id) {
- return message.channel.send('<:error:466995152976871434> You can\'t blacklist yourself!');
- };
-
- let blacklisted = false;
-
- if(settings.blacklisted.length > 0) {
- settings.blacklisted.forEach(function(ID) {
- if(ID == user.id) {
- blacklisted = true;
- }
- });
-
- if(blacklisted == true) {
- return message.channel.send('<:error:466995152976871434> This person has already been blacklisted!');
- };
- };
-
- client.settings.push(message.guild.id, user.id, "blacklisted")
-
- return message.channel.send(`<:success:466995111885144095> Blacklisted \`${user.user.tag}\``)
- };
-
-
- if (action == "remove") {
- if (!user) {
- let users;
- users = client.searchForMembers(message.guild, member);
- if (users.length > 1)
- return message.channel.send(
- "<:error:466995152976871434> Found multiple users! Please be more specific or mention the user instead."
- );
- else if (users.length == 0)
- return message.channel.send(
- "<:error:466995152976871434> That user doesn't seem to exist. Try again!"
- );
- user = users[0];
- };
-
- let blacklisted = false;
-
- settings.blacklisted.forEach(function(ID) {
- if(ID == user.id) {
- blacklisted = true;
- }
- });
-
- if(blacklisted != true) {
- return message.channel.send('<:error:466995152976871434> This user isn\'t blacklisted!');
- };
-
- client.settings.remove(message.guild.id, user.id, "blacklisted")
-
- return message.channel.send(`<:success:466995111885144095> Removed \`${user.user.tag}\` from the blacklist.`)
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Administrator",
- requiredPerms: []
-};
-
-exports.help = {
- name: "blacklist",
- category: "Moderation",
- description: "Allows you to configure Woomy's blacklist. Blacklisted users cannot use commands.",
- usage: "blacklist [add/remove] [member]"
-};
diff --git a/src/commands/bohemian_rhapsody.js b/src/commands/bohemian_rhapsody.js
deleted file mode 100644
index c9bb3ef..0000000
--- a/src/commands/bohemian_rhapsody.js
+++ /dev/null
@@ -1,45 +0,0 @@
-const Discord = require("discord.js");
-const lyric = require('../../resources/other/lyrics.json')
-exports.run = async (client, message, args, level) => {
- const lyrics = lyric.bohemian_rhapsody;
- var runtop = true;
- var runbottom = false;
- for(var br = 0; br < lyrics.length; br++) {
- {
- if (runtop === true) {
- var response = await client.awaitReply(message, lyrics[br]);
- runbottom = false;
- };
-
- if (runbottom === true) {
- if (response !== lyrics[br]) {
- return message.channel.send("Those aren't the lyrics!");
- }
- runtop = false
- };
- };
- if (runtop === true) {
- runtop = false
- runbottom = true
- } else if (runbottom === true) {
- runtop = true
- runbottom = false
- };
- };
- message.channel.send("What a lovely duet!");
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["br"],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "bohemian_rhapsody",
- category: "Fun",
- description: "Queen kareoke",
- usage: "bohemian_rhapsody"
-};
diff --git a/src/commands/calculate.js b/src/commands/calculate.js
deleted file mode 100644
index e7737b3..0000000
--- a/src/commands/calculate.js
+++ /dev/null
@@ -1,42 +0,0 @@
-var allowed = ["+", "-", "*", "/", "(", ")", " "];
-exports.run = (client, message, args) => {
- let exercise = args.join(" ");
-
- if (!exercise) {
- return message.channel.send(
- `<:error:466995152976871434> No equation provided. Usage :\`${client.commands.get(`calculate`).help.usage}\``
- );
- }
-
- for (var i = 0; i < exercise.length; i++) {
- let c = exercise.charAt(i);
- let found = allowed.find((element) => element === c);
-
- if(c == "0") found = true;
- if(!(Number(c) || found))
- {
- return message.channel.send(
- `<:error:466995152976871434> Invalid equation. Please use \`*\` for multiplication and \`/\` for division!`
- );
- }
- }
-
- let result = (new Function( 'return ' + exercise )());
-
- message.channel.send(`\`RESULT:\`\n\`\`\`${result}\`\`\``);
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["calc", "math"],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "calculate",
- category: "Utility",
- description: "Solves basic mathematical equations.",
- usage: "calculate [equation]"
-};
\ No newline at end of file
diff --git a/src/commands/cat.js b/src/commands/cat.js
deleted file mode 100644
index afd627f..0000000
--- a/src/commands/cat.js
+++ /dev/null
@@ -1,30 +0,0 @@
-const API = require('nekos.life');
-const {sfw} = new API();
-exports.run = async (client, message) => {
- message.channel.startTyping();
- try {
- sfw.meow().then((json) => {
- message.channel.send(json.url)
- message.channel.stopTyping();
- });
- } catch (err) {
- client.logger.error("cat.js: " + err);
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`)
- message.channel.stopTyping();
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "cat",
- category: "Image",
- description: "Sends you cat pics.",
- usage: "cat"
-};
diff --git a/src/commands/catfact.js b/src/commands/catfact.js
deleted file mode 100644
index 366999e..0000000
--- a/src/commands/catfact.js
+++ /dev/null
@@ -1,27 +0,0 @@
-const fetch = require("node-fetch")
-exports.run = async (bot, message, args) => {
- message.channel.startTyping();
- try{
- fetch('https://catfact.ninja/facts')
- .then(res => res.json())
- .then(json => message.channel.send(`__**Did you know?**__\n${json.data[0].fact}`))
- } catch(err) {
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`);
- };
- message.channel.stopTyping();
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["kittenfact"],
- permLevel: "User",
- requiredPerms: []
- };
-
- exports.help = {
- name: "catfact",
- category: "Fun",
- description: "Sends a fun fact about a cat.",
- usage: "catfact/kittenfact"
- };
diff --git a/src/commands/changelog.js b/src/commands/changelog.js
deleted file mode 100644
index a604a98..0000000
--- a/src/commands/changelog.js
+++ /dev/null
@@ -1,18 +0,0 @@
-exports.run = (client, message) => {
- message.channel.send(client.version.changelog)
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["updates"],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "changelog",
- category: "Utility",
- description: "Gives you the changes/features introduced with the latest update",
- usage: "changelog"
-};
diff --git a/src/commands/chatlogs.js b/src/commands/chatlogs.js
deleted file mode 100644
index 8faab92..0000000
--- a/src/commands/chatlogs.js
+++ /dev/null
@@ -1,29 +0,0 @@
-exports.run = async (client, message) => {
-
- const settings = message.settings;
-
- if (!client.settings.has(message.guild.id)) client.settings.set(message.guild.id, {});
-
- if (message.channel.name !== settings.chatlogsChannel) {
- client.settings.set(message.guild.id, message.channel.name, "chatlogsChannel")
- message.channel.send(`<:success:466995111885144095> Chat logs will now be displayed in \`${message.channel.name}\``);
- } else {
- client.settings.set(message.guild.id, "off", "chatlogsChannel")
- message.channel.send(`<:success:466995111885144095> Chat logs disabled.`);
- }
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Administrator",
- requiredPerms: []
-};
-
-exports.help = {
- name: "chatlogs",
- category: "Configure",
- description: "Enables chat logging in your server.",
- usage: "chatlogs **OR** chatlogs off"
-};
diff --git a/src/commands/coinflip.js b/src/commands/coinflip.js
deleted file mode 100644
index 418a996..0000000
--- a/src/commands/coinflip.js
+++ /dev/null
@@ -1,35 +0,0 @@
-exports.run = (client, message, args) => {
- if(!args[0]) {
- return message.channel.send(
- `<:error:466995152976871434> Invalid choice. Usage: \`${client.commands.get(`flip`).help.usage}\``
- );
- };
-
- if(args[0].toLowerCase() != "heads" && args[0].toLowerCase() != "tails") {
- return message.channel.send(
- `<:error:466995152976871434> Invalid choice. Usage: \`${client.commands.get(`flip`).help.usage}\``
- );
- };
- var coin = [
- "Heads!",
- "Tails!"
- ];
-
- let mess = coin.random();
- message.channel.send(mess);
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["flip"],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "coinflip",
- category: "Fun",
- description: "Flips a coin!",
- usage: "coinflip [heads/tails]"
-};
diff --git a/src/commands/colour.js b/src/commands/colour.js
deleted file mode 100644
index bdcbf61..0000000
--- a/src/commands/colour.js
+++ /dev/null
@@ -1,57 +0,0 @@
-const randomColour = require("randomcolor");
-exports.run = async (client, message, args, level) => {
- var colour;
- if(!args[0]) {
- colour = randomColour();
- } else if(isHex(args.join(" ")) != true) {
- colour = stringToHex(args.join(" "));
- } else {
- colour = args[0]
- }
-
- embed = new Discord.MessageEmbed();
- embed.setTitle(colour)
- embed.setColor(colour);
- embed.setImage("https://api.alexflipnote.xyz/colour/image/" + colour.replace("#", ""));
- message.channel.send(embed)
-};
-
-function isHex(string) {
- var str = string;
- if(str.charAt(0) == "#") {
- str = str.slice(1)
- };
-
- return typeof str === 'string'
- && str.length === 6
- && !isNaN(Number('0x' + str))
-}
-
-function stringToHex(string) {
- var hash = 0;
- for (var i = 0; i < string.length; i++) {
- hash = string.charCodeAt(i) + ((hash << 5) - hash);
- }
- var colour = '#';
- for (var i = 0; i < 3; i++) {
- var value = (hash >> (i * 8)) & 0xFF;
- colour += ('00' + value.toString(16)).substr(-2);
- }
- return colour;
-};
-
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["color"],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "colour",
- category: "Utility",
- description: "Gives you a random colour",
- usage: "colour **OR** colour "
-};
\ No newline at end of file
diff --git a/src/commands/credits.js b/src/commands/credits.js
deleted file mode 100644
index 5eb48ce..0000000
--- a/src/commands/credits.js
+++ /dev/null
@@ -1,20 +0,0 @@
-exports.run = async (client, message, args) => {
- message.channel.send(
- `__**Credits:**__\n• \`mudkipscience#8904\`, \`FLGX#9896\` and \`TheCakeChicken#9088\` for developing the bot\n• \`An Idiots Guide\` for the Guidebot bot base\n• \`Tina the Cyclops girl#0064\` for helping me not suck at coding\n• \`AirVentTrent\` for the icon, find him on Instagram\n• \`Terryiscool160\` for contributing to Woomy.`
- );
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "credits",
- category: "Utility",
- description: "Cool people",
- usage: "credits"
-};
diff --git a/src/commands/creeper.js b/src/commands/creeper.js
deleted file mode 100644
index 80ac90b..0000000
--- a/src/commands/creeper.js
+++ /dev/null
@@ -1,45 +0,0 @@
-
-const lyric = require('../../resources/other/lyrics.json')
-exports.run = async (client, message, args, level) => {
- var lyrics = lyric.creeper;
-
- var runtop = true;
- var runbottom = false;
- for(var br = 0; br < lyrics.length; br++) {
- {
- if (runtop === true) {
- var response = await client.awaitReply(message, lyrics[br]);
- runbottom = false;
- };
-
- if (runbottom === true) {
- if (response !== lyrics[br]) {
- return message.channel.send("Those aren't the lyrics!")
- }
- runtop = false
- };
- } if (runtop === true) {
- runtop = false
- runbottom = true
- } else if (runbottom === true) {
- runtop = true
- runbottom = false
- }
- }
- message.channel.send("What a lovely duet!")
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "creeper",
- category: "Fun",
- description: "Aww man",
- usage: "creeper"
-};
diff --git a/src/commands/cuddle.js b/src/commands/cuddle.js
deleted file mode 100644
index 63263ae..0000000
--- a/src/commands/cuddle.js
+++ /dev/null
@@ -1,69 +0,0 @@
-const API = require('nekos.life');
-const {sfw} = new API();
-exports.run = async (client, message, args) => {
- if(!args[0]) {
- return message.channel.send(`<:error:466995152976871434> You didn't say who you wanted to cuddle! Usage: \`${client.commands.get(`cuddle`).help.usage}\``)
- };
-
- var people = "";
-
- for (var i = 0; i < args.length; i++) {
- var user = client.getUserFromMention(args[i])
- if (user) {
- user = message.guild.members.cache.get(user.id).displayName;
- } else {
- users = client.searchForMembers(message.guild, args[i]);
- if (users.length > 1)
- return message.channel.send(
- "<:error:466995152976871434> Found multiple users for `" + args[i] + "`, Please be more specific or mention the user instead."
- );
- else if (users.length == 0)
- return message.channel.send(
- "<:error:466995152976871434> That user doesn't seem to exist. Try again!"
- );
- user = users[0].displayName;
- };
- if(i+1 == args.length && args.length > 1) {
- people += `**and** ${user}!`
- } else if(args.length < 2) {
- people += `${user}!`;
- } else if(args.length == 2 && i == 0) {
- people += `${user} `;
- } else {
- people += `${user}, `;
- };
- };
-
-
-
- message.channel.startTyping();
- try {
- sfw.cuddle().then((json) => {
- embed = new Discord.MessageEmbed();
- embed.setImage(json.url)
- embed.setColor(client.embedColour(message));
- embed.setDescription(`**${message.guild.members.cache.get(message.author.id).displayName}** cuddled **${people}**`)
- message.channel.send(embed)
- message.channel.stopTyping();
- });
- } catch (err) {
- client.logger.error("cuddle.js: " + err);
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`)
- message.channel.stopTyping();
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "cuddle",
- category: "Action",
- description: "cuddle someone!",
- usage: "cuddle [@user/user] (you can cuddle as many people as you want!)"
-};
diff --git a/src/commands/dice.js b/src/commands/dice.js
deleted file mode 100644
index be9edcf..0000000
--- a/src/commands/dice.js
+++ /dev/null
@@ -1,27 +0,0 @@
-exports.run = async (bot, message, args) => {
- if (args.length === 0) {
- message.channel.send(`🎲 You rolled a ${Array.from(Array(6).keys()).random() + 1}!`);
- } else {
- if (args[0].match(/^\d+$/)) {
- message.channel.send(`🎲 You rolled a ${Array.from(Array(parseInt(args[0])).keys()).random() + 1}!`);
- } else {
- message.channel.send(`🎲 You rolled a ${Array.from(Array(6).keys()).random() + 1}!`);
- }
- }
- };
-
- exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["diceroll", "roll"],
- permLevel: "User",
- requiredPerms: []
- };
-
- exports.help = {
- name: "dice",
- category: "Fun",
- description: "Rolls a dice.",
- usage: "dice "
- };
-
diff --git a/src/commands/dog.js b/src/commands/dog.js
deleted file mode 100644
index 39ce25c..0000000
--- a/src/commands/dog.js
+++ /dev/null
@@ -1,30 +0,0 @@
-const API = require('nekos.life');
-const {sfw} = new API();
-exports.run = async (client, message) => {
- message.channel.startTyping();
- try {
- sfw.woof().then((json) => {
- message.channel.send(json.url)
- message.channel.stopTyping();
- });
- } catch (err) {
- client.logger.error("dog.js: " + err);
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`)
- message.channel.stopTyping();
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "dog",
- category: "Image",
- description: "Sends you dog pics.",
- usage: "dog"
-};
diff --git a/src/commands/dogfact.js b/src/commands/dogfact.js
deleted file mode 100644
index fca8a62..0000000
--- a/src/commands/dogfact.js
+++ /dev/null
@@ -1,27 +0,0 @@
-const fetch = require("node-fetch");
-exports.run = async (bot, message, args) => {
- message.channel.startTyping();
- try{
- fetch('https://dog-api.kinduff.com/api/facts')
- .then(res => res.json())
- .then(json => message.channel.send(`__**Did you know?**__\n ${json.facts[0]}`));
- } catch(err) {
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`);
- };
- message.channel.stopTyping();
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["pupfact"],
- permLevel: "User",
- requiredPerms: []
- };
-
- exports.help = {
- name: "dogfact",
- category: "Fun",
- description: "Sends a fun fact about a doggo.",
- usage: "dogfact/pupfact"
- };
diff --git a/src/commands/emoji.js b/src/commands/emoji.js
deleted file mode 100644
index ab6907b..0000000
--- a/src/commands/emoji.js
+++ /dev/null
@@ -1,42 +0,0 @@
-exports.run = async (client, message, args) => {
- if(!args[0]) {
- return message.channel.send(`You need to specify a custom emoji. Usage: \`${client.commands.get(`emoji`).help.usage}\``)
- };
-
- var ID;
- var format = ".png"
- var string = args[0].replace(/\D/g,'');
-
- if(args[0].charAt(1) == "a" && args[0].charAt(2) == ":") {
- format = ".gif"
- };
-
- if(string.length > 18) {
- ID = string.slice(string.length - 18);
- } else {
- ID = string;
- };
-
- if(!ID) {
- return message.channel.send(`<:error:466995152976871434> Invalid emoji. This command only works with custom emojis.`)
- };
-
-
-
- message.channel.send("https://cdn.discordapp.com/emojis/" + ID + format)
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "emoji",
- category: "Utility",
- description: "Enlarges and links an custom emoji",
- usage: "emoji [emoji]"
-};
diff --git a/src/commands/emojify.js b/src/commands/emojify.js
deleted file mode 100644
index 46dfa35..0000000
--- a/src/commands/emojify.js
+++ /dev/null
@@ -1,56 +0,0 @@
-Discord = require("discord.js");
-exports.run = (client, message, args) => {
- if (!args[0]) {
- return message.channel.send(
- `<:error:466995152976871434> You must include a message for me to emojify! Usage: \`${client.commands.get(`emojify`).help.usage}\``
- );
- };
- const specialChars = {
- '0': ':zero:',
- '1': ':one:',
- '2': ':two:',
- '3': ':three:',
- '4': ':four:',
- '5': ':five:',
- '6': ':six:',
- '7': ':seven:',
- '8': ':eight:',
- '9': ':nine:',
- '#': ':hash:',
- '*': ':asterisk:',
- '?': ':grey_question:',
- '!': ':grey_exclamation:',
- ' ': ' '
- };
-
- const emojified = `${args.join(' ')}`.toLowerCase().split('').map(letter => {
- if (/[a-z]/g.test(letter)) {
- return `:regional_indicator_${letter}: `
- } else if (specialChars[letter]) {
- return `${specialChars[letter]} `
- };
- return letter
- }).join('');
-
- if(emojified.length > 2000) {
- return message.channel.send("<:error:466995152976871434> The emojified message exceeds 2000 characters.")
- };
-
- message.channel.send(emojified);
-};
-
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "emojify",
- category: "Fun",
- description: "Changes text into emojis",
- usage: "emojify [message]"
-};
diff --git a/src/commands/eval.js b/src/commands/eval.js
deleted file mode 100644
index 2fef95f..0000000
--- a/src/commands/eval.js
+++ /dev/null
@@ -1,46 +0,0 @@
-const hastebin = require('hastebin-gen');
-exports.run = async (client, message, args) => {
- const code = args.join(" ");
- try {
- const evaled = eval(code);
- const clean = await client.clean(client, evaled);
-
- if(clean.length > 2000) {
- hastebin(clean, { extension: "txt" }).then(haste => {
- return message.channel.send('`OUTPUT`\n' + haste);
- }).catch(error => {
- client.logger.err(error);
- });
-
- return;
- }
- message.channel.send(`\`OUTPUT\` \`\`\`js\n${await clean}\n\`\`\``);
- } catch (err) {
- const errclean = await client.clean(client, err);
- if(errclean.length > 2000) {
- hastebin(errclean, { extension: "txt" }).then(haste => {
- return message.channel.send('`ERROR`\n' + haste);
- }).catch(error => {
- client.logger.err(error);
- });
-
- return;
- }
- message.channel.send(`\`ERROR\` \`\`\`xl\n${await errclean}\n\`\`\``);
- }
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "Developer",
- requiredPerms: []
-};
-
-exports.help = {
- name: "eval",
- category: "Owner",
- description: "Evaluates arbitrary javascript.",
- usage: "eval [code]"
-};
diff --git a/src/commands/fact.js b/src/commands/fact.js
deleted file mode 100644
index 0e351a6..0000000
--- a/src/commands/fact.js
+++ /dev/null
@@ -1,30 +0,0 @@
-const API = require('nekos.life');
-const {sfw} = new API();
-exports.run = async (client, message) => {
- message.channel.startTyping();
- try {
- sfw.fact().then((json) => {
- message.channel.send("__**Did you know?**__\n" + json.fact + ".");
- message.channel.stopTyping();
- });
- } catch (err) {
- client.logger.error("fact.js: " + err);
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`)
- message.channel.stopTyping();
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["randomfact"],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "fact",
- category: "Fun",
- description: "Sends you a random fact.",
- usage: "fact"
-};
diff --git a/src/commands/feed.js b/src/commands/feed.js
deleted file mode 100644
index 9749f45..0000000
--- a/src/commands/feed.js
+++ /dev/null
@@ -1,69 +0,0 @@
-const API = require('nekos.life');
-const {sfw} = new API();
-exports.run = async (client, message, args) => {
- if(!args[0]) {
- return message.channel.send(`<:error:466995152976871434> You didn't say who you wanted to feed! Usage: \`${client.commands.get(`feed`).help.usage}\``)
- };
-
- var people = "";
-
- for (var i = 0; i < args.length; i++) {
- var user = client.getUserFromMention(args[i])
- if (user) {
- user = message.guild.members.cache.get(user.id).displayName;
- } else {
- users = client.searchForMembers(message.guild, args[i]);
- if (users.length > 1)
- return message.channel.send(
- "<:error:466995152976871434> Found multiple users for `" + args[i] + "`, Please be more specific or mention the user instead."
- );
- else if (users.length == 0)
- return message.channel.send(
- "<:error:466995152976871434> That user doesn't seem to exist. Try again!"
- );
- user = users[0].displayName;
- };
- if(i+1 == args.length && args.length > 1) {
- people += `**and** ${user}!`
- } else if(args.length < 2) {
- people += `${user}!`;
- } else if(args.length == 2 && i == 0) {
- people += `${user} `;
- } else {
- people += `${user}, `;
- };
- };
-
-
-
- message.channel.startTyping();
- try {
- sfw.feed().then((json) => {
- embed = new Discord.MessageEmbed();
- embed.setImage(json.url)
- embed.setColor(client.embedColour(message));
- embed.setDescription(`**${message.guild.members.cache.get(message.author.id).displayName}** fed **${people}**`)
- message.channel.send(embed)
- message.channel.stopTyping();
- });
- } catch (err) {
- client.logger.error("feed.js: " + err);
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`)
- message.channel.stopTyping();
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "feed",
- category: "Action",
- description: "feed someone!",
- usage: "feed [@user/user] (you can feed as many people as you want!)"
-};
diff --git a/src/commands/feedback.js b/src/commands/feedback.js
deleted file mode 100644
index 6b4512b..0000000
--- a/src/commands/feedback.js
+++ /dev/null
@@ -1,28 +0,0 @@
-exports.run = (client, message, args, level) => {
- if(!args[0]) return message.channel.send(`<:error:466995152976871434> You didn't give me any feedback! Usage: \`${client.commands.get(`feedback`).help.usage}\``)
- const feedback = args.join(" ")
- let guild = client.guilds.cache.get("410990517841690625")
- let channel = guild.channels.cache.get("438825830949453824")
- let embed = new Discord.MessageEmbed()
- .setTitle(`Feedback:`)
- .setColor(client.embedColour(message))
- .addField("User:",message.author.tag)
- .addField("Feedback: ", feedback)
- channel.send({embed: embed})
- message.channel.send("<:success:466995111885144095> Your feedback has been sent to my developer. Thank you!")
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["suggest"],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "feedback",
- category: "Utility",
- description: "Send feedback to my developer.",
- usage: "feedback [message]"
-};
diff --git a/src/commands/forceskip.js b/src/commands/forceskip.js
deleted file mode 100644
index 7e341d6..0000000
--- a/src/commands/forceskip.js
+++ /dev/null
@@ -1,28 +0,0 @@
-exports.run = (client, message) => {
- let guild = client.music.getGuild(message.guild.id);
-
- if(guild.queue.length < 1) return message.channel.send(
- `<:error:466995152976871434> There is nothing for me to skip!`
- );
- skip_song(guild);
- message.channel.send("<:skip:467216735356059660> Skipped the song!")
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Moderator",
- requiredPerms: ["SPEAK"]
-};
-
-exports.help = {
- name: "forceskip",
- category: "Music",
- description: "Skips the currently playing song without requiring a vote.",
- usage: "forceskip"
-};
-
-function skip_song(guild) {
- guild.dispatcher.end();
-}
diff --git a/src/commands/foxgirl.js b/src/commands/foxgirl.js
deleted file mode 100644
index f3f3312..0000000
--- a/src/commands/foxgirl.js
+++ /dev/null
@@ -1,30 +0,0 @@
-const API = require('nekos.life');
-const {sfw} = new API();
-exports.run = async (client, message) => {
- message.channel.startTyping();
- try {
- sfw.foxGirl().then((json) => {
- message.channel.send(json.url)
- message.channel.stopTyping();
- });
- } catch (err) {
- client.logger.error("foxgirl.js: " + err);
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`)
- message.channel.stopTyping();
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "foxgirl",
- category: "Image",
- description: "Sends you pictures of fox girls.",
- usage: "foxgirl"
-};
diff --git a/src/commands/garfield.js b/src/commands/garfield.js
deleted file mode 100644
index 5376ded..0000000
--- a/src/commands/garfield.js
+++ /dev/null
@@ -1,21 +0,0 @@
-const garfield = require("garfield");
-exports.run = async (client, message) => {
- message.channel.send({ files: [garfield.random()] }).catch(() => message.channel.send(
- "<:error:466995152976871434> API didn't respond, try again in a few seconds."
- ));
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: ["ATTACH_FILES"]
-};
-
-exports.help = {
- name: "garfield",
- category: "Fun",
- description: "Sends you a random garfield comic",
- usage: "garfield"
-};
diff --git a/src/commands/giverole.js b/src/commands/giverole.js
deleted file mode 100644
index f62a055..0000000
--- a/src/commands/giverole.js
+++ /dev/null
@@ -1,87 +0,0 @@
-exports.run = async (client, message, [member, ...role2add], query) => {
- if (!member) {
- return message.channel.send(
- "<:error:466995152976871434> Who am I meant to give a role?"
- );
- }
- let user = message.mentions.members.first();
- let users;
- if (!user) {
- users = client.searchForMembers(message.guild, member);
- if (users.length > 1)
- return message.channel.send(
- "<:error:466995152976871434> Found multiple users! Please be more specific or mention the user instead."
- );
- else if (users.length == 0)
- return message.channel.send(
- "<:error:466995152976871434> That user doesn't seem to exist. Try again!"
- );
- user = users[0];
- }
- let joinedValue = role2add.join(" ");
-
- let gRole = client.findRole(joinedValue, message);
-
- if (!gRole) {
- return message.channel.send(`<:error:466995152976871434> That role doesn't seem to exist. Try again!`);
- };
-
- let moderator = message.guild.member(message.author)
- if (gRole.position >= moderator.roles.highest.position) {
- return message.channel.send(
- "<:error:466995152976871434> You cannot give roles higher than your own!"
- );
- }
-
- var bot = message.guild.members.cache.get(client.user.id)
- if (gRole.position >= bot.roles.highest.position) {
- return message.channel.send(
- `<:error:466995152976871434> I cannot give roles higher than my own!`
- );
- }
-
- if (user.roles.cache.has(gRole.id)) {
- return message.channel.send(
- "<:error:466995152976871434> They already have that role!"
- );
- }
-
- await user.roles.add(gRole.id);
- message.channel.send(
- `<:success:466995111885144095> Gave \`${user.user.tag}\` the \`${gRole.name}\` role.`
- );
-
- if (client.getSettings(message.guild.id).modlogsChannel !== "off") {
- const channel = message.guild.channels.cache.find(
- channel => channel.name === client.getSettings(message.guild.id).modlogsChannel
- );
-
- if (channel) {
- let embed = new Discord.MessageEmbed();
- embed.setColor("#00c09a");
- embed.setAuthor("Role given:", user.user.avatarURL({format: "png", dynamic: true, size: 2048}));
- embed.setDescription(`• User: ${user} (${user.user.id})\n• Mod: ${message.author} (${message.author.id})\n• Role: ${gRole}`)
- try {
- channel.send({ embed });
- } catch (err) {
- // probably no permissions to send messages/embeds there
- };
- };
- };
-
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: ["addrole"],
- permLevel: "Moderator",
- requiredPerms: ["MANAGE_ROLES"]
-};
-
-exports.help = {
- name: "giverole",
- category: "Moderation",
- description: "Gives the user the specified role.",
- usage: "giverole [user] [role]"
-};
diff --git a/src/commands/goodbye.js b/src/commands/goodbye.js
deleted file mode 100644
index f22d1cf..0000000
--- a/src/commands/goodbye.js
+++ /dev/null
@@ -1,42 +0,0 @@
-exports.run = async (client, message, args, level) => {
-
- const settings = message.settings;
- if (!client.settings.has(message.guild.id)) client.settings.set(message.guild.id, {});
-
- if (args[0]) {
- const joinedValue = args.join(" ");
- if (joinedValue === settings.welcomeMessage) return message.channel.send(
- "<:error:466995152976871434> The leave message is already set to that!"
- );
- if (!client.settings.has(message.guild.id)) client.settings.set(message.guild.id, {});
- if (joinedValue === "off") {
- if (!client.settings.has(message.guild.id)) client.settings.set(message.guild.id, {});
- client.settings.set(message.guild.id, "off", "leaveMessage");
- return message.channel.send(`<:success:466995111885144095> Leave messages have been disabled.`);
- }
- client.settings.set(message.guild.id, joinedValue, "leaveMessage");
- client.settings.set(message.guild.id, message.channel.id, "welcomeChannel")
- message.channel.send(`<:success:466995111885144095> Set the leave message to \`${joinedValue}\``);
- } else {
- if (settings.leaveMessage === "off") {
- message.channel.send(`Leave messages are off.`)
- } else {
- message.channel.send(`The current leave message is: \`${settings.leaveMessage}\``)
- }
- }
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Administrator",
- requiredPerms: []
-};
-
-exports.help = {
- name: "goodbye",
- category: "Configure",
- description: "Sets the leave message for this server. try using [[server]], [[user]] and [[members]] in your message!",
- usage: "goodbye **OR** goodbye off"
-};
diff --git a/src/commands/hackban.js b/src/commands/hackban.js
deleted file mode 100644
index ff4d1cb..0000000
--- a/src/commands/hackban.js
+++ /dev/null
@@ -1,60 +0,0 @@
-exports.run = async (client, message, args) => {
- const settings = (message.settings = client.getSettings(message.guild.id));
-
- if(!args[0]) {
- return message.channel.send(
- `<:error:466995152976871434> No user ID provided. Usage: \`${client.commands.get(`hackban`).help.usage}\``
- );
- };
-
- user = client.users.cache.get(args[0])
- if(!user) {
- return message.channel.send("<:error:466995152976871434> Invalid ID")
- }
-
- if(message.guild.member(args[0])) {
- if(!message.guild.member(args[0]).bannable) {
- return message.channel.send("<:error:466995152976871434> User is not bannable.")
- }
- }
-
- let reason = args.slice(1).join(" ");
- if (!reason) reason = `Banned by ${message.author.tag}`;
- await message.guild.members.ban(args[0], {reason: reason}).catch(console.error);
- message.channel.send(`<:success:466995111885144095> Hackbanned \`${user.tag}\``);
-
- if (settings.modlogsChannel !== "off") {
- const channel = message.guild.channels.cache.find(
- channel => channel.name === settings.modlogsChannel
- );
-
- if (channel) {
- let embed = new Discord.MessageEmbed();
- embed.setColor("#BC0057");
- embed.setAuthor("User banned!", user.avatarURL({format: "png", dynamic: true, size: 2048}));
- embed.setDescription(
- `• User: ${user.tag} (${user.id})\n• Mod: ${message.author} (${message.author.id})\n• Reason: ${reason}`
- );
- try {
- channel.send(embed);
- } catch (err) {
- // probably no permissions to send messages/embeds there
- };
- }
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Moderator",
- requiredPerms: ["BAN_MEMBERS"]
-};
-
-exports.help = {
- name: "hackban",
- category: "Moderation",
- description: "Ban users who are not in the server.",
- usage: "ban [userID] "
-};
diff --git a/src/commands/help.js b/src/commands/help.js
deleted file mode 100644
index 5c07963..0000000
--- a/src/commands/help.js
+++ /dev/null
@@ -1,174 +0,0 @@
-exports.run = (client, message, args, level) => {
- embed = new Discord.MessageEmbed();
- embed.setColor(client.embedColour(message));
-
- var ran = false;
- var output = "";
- var commands = 0;
- var prefix;
- var currentCategory;
-
- if(message.guild) {
- prefix = message.settings.prefix;
- } else {
- prefix = client.config.defaultSettings.prefix;
- };
-
- if(!args[0]) {
- embed.setTitle(`Command list`);
- embed.setDescription(`For more information on a specific command use \`${prefix}help \`\nFor the full command list use \`${prefix}help all\`\n`);
-
- const myCommands = message.guild ? client.commands.filter(
- cmd => client.levelCache[cmd.conf.permLevel] <= level
- ) : client.commands.filter(
- cmd => client.levelCache[cmd.conf.permLevel] <= level && cmd.conf.guildOnly !== true
- );
-
- const commandNames = myCommands.keyArray();
- const longest = commandNames.reduce(
- (long, str) => Math.max(long, str.length),
- 0
- );
-
- const sorted = myCommands.array().sort(
- (p, c) => p.help.category > c.help.category ? 1 : p.help.name > c.help.name && p.help.category === c.help.category ? 1 : -1
- );
-
- sorted.forEach( c => {
- const cat = c.help.category;
- if (currentCategory !== cat) {
- if(ran == true) {
- embed.addField(currentCategory + ` [${commands}]`, output)
- output = "";
- commands = 0;
- }
- currentCategory = cat;
- ran = true
- }
- output += `\`${c.help.name}\` `;
- commands = commands + 1;
- });
-
- embed.addField(currentCategory + ` [${commands}]`, output);
-
- embed.addField(
- "Invite me",
- "[Click here](https://discordapp.com/oauth2/authorize?client_id=435961704145485835&permissions=8&scope=bot) to add me to your server",
- true
- );
- embed.addField(
- "Support",
- "[Click here](https://discord.gg/HCF8mdv) if bot broke",
- true
- );
-
- message.channel.send(embed);
-
- return;
- };
-
- if(args[0].toLowerCase() == "all") {
- embed.setTitle(`Command list`);
- embed.setDescription(`For more information on a specific command use \`${prefix}help \`\nFor the full command list use \`${prefix}help all\`\n`);
-
- const myCommands = client.commands
-
- const commandNames = myCommands.keyArray();
- const longest = commandNames.reduce(
- (long, str) => Math.max(long, str.length),
- 0
- );
-
- const sorted = myCommands.array().sort(
- (p, c) => p.help.category > c.help.category ? 1 : p.help.name > c.help.name && p.help.category === c.help.category ? 1 : -1
- );
-
- sorted.forEach( c => {
- const cat = c.help.category;
- if (currentCategory !== cat) {
- if(ran == true) {
- embed.addField(currentCategory + ` [${commands}]`, output)
- output = "";
- commands = 0;
- }
- currentCategory = cat;
- ran = true
- }
- output += `\`${c.help.name}\` `;
- commands = commands + 1;
- });
-
-
- embed.addField(currentCategory + ` [${commands}]`, output);
-
- embed.addField(
- "Invite me",
- "[Click here](https://discordapp.com/oauth2/authorize?client_id=435961704145485835&permissions=8&scope=bot) to add me to your server",
- true
- );
- embed.addField(
- "Support",
- "[Click here](https://discord.gg/HCF8mdv) if bot broke",
- true
- );
-
- message.channel.send(embed);
-
- return;
- };
-
- if(args[0]) {
- let command = args.shift().toLowerCase();
- let cmd = client.commands.get(command) || client.commands.get(client.aliases.get(command));
-
- if(!client.commands.has(command)) {
- return message.channel.send("<:error:466995152976871434> That command doesn't exist!")
- };
-
- command = client.commands.get(command);
-
- var requiredPerms = "";
-
- if(cmd.conf.requiredPerms.length > 0 ) {
- requiredPerms = "`" + cmd.conf.requiredPerms.join("`, `") + "`";
- } else {
- requiredPerms = "None";
- };
-
- var aliases = "";
-
- if(cmd.conf.aliases.length > 0 ) {
- aliases = "`" + cmd.conf.aliases.join("`, `") + "`";
- } else {
- aliases = "None";
- };
-
-
-
- embed.setTitle(prefix + command.help.name);
- embed.setDescription(
- `• **Description:** ${command.help.description}\n• **Usage:** ${prefix + command.help.usage}\n• **Permission Level:** ${cmd.conf.permLevel} \n• **Guild Only:** ${cmd.conf.guildOnly}\n• **Aliases:** ${aliases}\n• **Required perms:** ${requiredPerms}`
- );
- embed.setFooter("Arguments in [] are required, <> are optional.");
-
- message.channel.send(embed);
-
- return;
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["h", "cmds"],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "help",
- category: "Utility",
- description:
- "Displays all the commands you are able to use.",
- usage: "help **OR** help all"
-};
\ No newline at end of file
diff --git a/src/commands/hug.js b/src/commands/hug.js
deleted file mode 100644
index 30ef214..0000000
--- a/src/commands/hug.js
+++ /dev/null
@@ -1,69 +0,0 @@
-const API = require('nekos.life');
-const {sfw} = new API();
-exports.run = async (client, message, args) => {
- if(!args[0]) {
- return message.channel.send(`<:error:466995152976871434> You didn't say who you wanted to hug! Usage: \`${client.commands.get(`hug`).help.usage}\``)
- };
-
- var people = "";
-
- for (var i = 0; i < args.length; i++) {
- var user = client.getUserFromMention(args[i])
- if (user) {
- user = message.guild.members.cache.get(user.id).displayName;
- } else {
- users = client.searchForMembers(message.guild, args[i]);
- if (users.length > 1)
- return message.channel.send(
- "<:error:466995152976871434> Found multiple users for `" + args[i] + "`, Please be more specific or mention the user instead."
- );
- else if (users.length == 0)
- return message.channel.send(
- "<:error:466995152976871434> That user doesn't seem to exist. Try again!"
- );
- user = users[0].displayName;
- };
- if(i+1 == args.length && args.length > 1) {
- people += `**and** ${user}!`
- } else if(args.length < 2) {
- people += `${user}!`;
- } else if(args.length == 2 && i == 0) {
- people += `${user} `;
- } else {
- people += `${user}, `;
- };
- };
-
-
-
- message.channel.startTyping();
- try {
- sfw.hug().then((json) => {
- embed = new Discord.MessageEmbed();
- embed.setImage(json.url)
- embed.setColor(client.embedColour(message));
- embed.setDescription(`**${message.guild.members.cache.get(message.author.id).displayName}** hugged **${people}**`)
- message.channel.send(embed)
- message.channel.stopTyping();
- });
- } catch (err) {
- client.logger.error("hug.js: " + err);
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`)
- message.channel.stopTyping();
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "hug",
- category: "Action",
- description: "Hug someone!",
- usage: "hug [@user/user] (you can hug as many people as you want!)"
-};
diff --git a/src/commands/identity.js b/src/commands/identity.js
deleted file mode 100644
index b7f3809..0000000
--- a/src/commands/identity.js
+++ /dev/null
@@ -1,36 +0,0 @@
-const identities = require ("../../resources/other/identities.json");
-exports.run = async (client, message, args) => {
- var output = "";
- if(!args[0]) {
- for (var key of Object.keys(identities)) {
- output += `${key}, `
- };
- return message.channel.send(`__**Identities**__\n${output.slice(0, -2)}`);
- } else {
- if(args.join(" ").toLowerCase() == "attack helicopter" || args.join(" ").toLowerCase() == "apache attack helicopter" || args.join(" ").toLowerCase() == "apache") {
- return message.channel.send({
- files: [new Discord.MessageAttachment("./resources/images/attackhelicopter.jpg")]
- });
- }
- output = identities[args.join(" ").toLowerCase()];
- if(!output) {
- return message.channel.send("<:error:466995152976871434> No results for that query.");
- };
- return message.channel.send(`__**${output.name.toProperCase()}**__\n${output.description}`);
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["identities"],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "identity",
- category: "Fun",
- description: "Gives you information about the specified identity.",
- usage: "identity [identity]"
-};
diff --git a/src/commands/inspirobot.js b/src/commands/inspirobot.js
deleted file mode 100644
index 17a028f..0000000
--- a/src/commands/inspirobot.js
+++ /dev/null
@@ -1,28 +0,0 @@
-const fetch = require("node-fetch")
-exports.run = async (client, message) => {
- message.channel.startTyping();
- try {
- fetch('http://inspirobot.me/api?generate=true')
- .then(res => res.text())
- .then(body => message.channel.send({files: [new Discord.MessageAttachment(body)]}));
- message.channel.stopTyping();
- } catch (err) {
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`)
- message.channel.stopTyping();
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["inspire"],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "inspirobot",
- category: "Fun",
- description: "Returns an inspirational message generated by inspirobot.",
- usage: "inspirobot"
-};
diff --git a/src/commands/invite.js b/src/commands/invite.js
deleted file mode 100644
index 49cdc86..0000000
--- a/src/commands/invite.js
+++ /dev/null
@@ -1,20 +0,0 @@
-exports.run = async (client, message) => {
- message.channel.send(
- `Use this link to invite me to your server:\n`
- );
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "invite",
- category: "Utility",
- description: "Sends you a link so you can add Woomy to your own servers",
- usage: "invite"
-};
diff --git a/src/commands/kemonomimi.js b/src/commands/kemonomimi.js
deleted file mode 100644
index 3c4b70e..0000000
--- a/src/commands/kemonomimi.js
+++ /dev/null
@@ -1,30 +0,0 @@
-const API = require('nekos.life');
-const {sfw} = new API();
-exports.run = async (client, message) => {
- message.channel.startTyping();
- try {
- sfw.kemonomimi().then((json) => {
- message.channel.send(json.url)
- message.channel.stopTyping();
- });
- } catch (err) {
- client.logger.error("kemonomimi.js: " + err);
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`)
- message.channel.stopTyping();
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "kemonomimi",
- category: "Image",
- description: "Sends you pictures of people with animal characteristics.",
- usage: "kemonomimi"
-};
diff --git a/src/commands/kick.js b/src/commands/kick.js
deleted file mode 100644
index 9070a98..0000000
--- a/src/commands/kick.js
+++ /dev/null
@@ -1,87 +0,0 @@
-exports.run = async (client, message, args) => {
- const settings = client.getSettings(message.guild.id);
-
- if(!args[0]) {
- return message.channel.send("<:error:466995152976871434> Who am I meant to kick?")
- }
-
- let user = message.mentions.members.first();
-
- if (!user) {
- let users;
- users = client.searchForMembers(message.guild, args[0]);
- if (users.length > 1)
- return message.channel.send(
- "<:error:466995152976871434> Found multiple users! Please be more specific or mention the user instead."
- );
- else if (users.length == 0)
- return message.channel.send(
- "<:error:466995152976871434> That user doesn't seem to exist. Try again!"
- );
- user = users[0];
- }
-if (user.user.id === client.user.id) {
- return message.channel.send("lol no")
-}
-if (user.user.id === message.guild.owner.id) {
- return message.channel.send("<:error:466995152976871434> You can't kick the owner!")
-}
-let moderator = message.guild.member(message.author)
-if (user.roles.highest.position >= moderator.roles.highest.position && moderator.user.id !== message.guild.ownerID) {
- return message.channel.send(
- `<:error:466995152976871434> You can't kick people higher ranked than yourself!`
- );
-}
-
-let bot = message.guild.member(client.user)
-if (user.roles.highest.position >= bot.roles.highest.position) {
- return message.channel.send(
- `<:error:466995152976871434> I can't kick people who are higher ranked than me!`
- );
-}
-
-if (!user.bannable)
- return message.channel.send(
- "<:error:466995152976871434> Specified user is not bannable."
- );
-
-let reason = args.slice(1).join(" ");
-if (!reason) reason = `Kicked by ${message.author.tag}`;
-await user.kick(reason).catch(console.error);
-message.channel.send(`<:success:466995111885144095> Kicked \`${user.user.tag}\``);
-
-if (settings.modlogsChannel !== "off") {
- const channel = message.guild.channels.cache.find(
- channel => channel.name === settings.modlogsChannel
- );
-
- if (channel) {
- let embed = new Discord.MessageEmbed();
- embed.setColor("#fd0061");
- embed.setAuthor("User kicked!", user.user.avatarURL({format: "png", dynamic: true, size: 2048}));
- embed.setDescription(
- `• User: ${user.user.tag} (${user.user.id})\n• Mod: ${message.author} (${message.author.id})\n• Reason: ${reason}`
- );
- try {
- channel.send({ embed });
- } catch (err) {
- // probably no permissions to send messages/embeds there
- };
- };
-};
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Moderator",
- requiredPerms: ["KICK_MEMBERS"]
-};
-
-exports.help = {
- name: "kick",
- category: "Moderation",
- description: "Kicks specified user.",
- usage: "kick [user] "
-};
diff --git a/src/commands/kiss.js b/src/commands/kiss.js
deleted file mode 100644
index 495ee62..0000000
--- a/src/commands/kiss.js
+++ /dev/null
@@ -1,69 +0,0 @@
-const API = require('nekos.life');
-const {sfw} = new API();
-exports.run = async (client, message, args) => {
- if(!args[0]) {
- return message.channel.send(`<:error:466995152976871434> You didn't say who you wanted to kiss! Usage: \`${client.commands.get(`kiss`).help.usage}\``)
- };
-
- var people = "";
-
- for (var i = 0; i < args.length; i++) {
- var user = client.getUserFromMention(args[i])
- if (user) {
- user = message.guild.members.cache.get(user.id).displayName;
- } else {
- users = client.searchForMembers(message.guild, args[i]);
- if (users.length > 1)
- return message.channel.send(
- "<:error:466995152976871434> Found multiple users for `" + args[i] + "`, Please be more specific or mention the user instead."
- );
- else if (users.length == 0)
- return message.channel.send(
- "<:error:466995152976871434> That user doesn't seem to exist. Try again!"
- );
- user = users[0].displayName;
- };
- if(i+1 == args.length && args.length > 1) {
- people += `**and** ${user}!`
- } else if(args.length < 2) {
- people += `${user}!`;
- } else if(args.length == 2 && i == 0) {
- people += `${user} `;
- } else {
- people += `${user}, `;
- };
- };
-
-
-
- message.channel.startTyping();
- try {
- sfw.kiss().then((json) => {
- embed = new Discord.MessageEmbed();
- embed.setImage(json.url)
- embed.setColor(client.embedColour(message));
- embed.setDescription(`**${message.guild.members.cache.get(message.author.id).displayName}** kissed **${people}**`)
- message.channel.send(embed)
- message.channel.stopTyping();
- });
- } catch (err) {
- client.logger.error("kiss.js: " + err);
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`)
- message.channel.stopTyping();
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "kiss",
- category: "Action",
- description: "Kiss someone!",
- usage: "kiss [@user/user] (you can kiss as many people as you want!)"
-};
diff --git a/src/commands/lizard.js b/src/commands/lizard.js
deleted file mode 100644
index f476704..0000000
--- a/src/commands/lizard.js
+++ /dev/null
@@ -1,30 +0,0 @@
-const API = require('nekos.life');
-const {sfw} = new API();
-exports.run = async (client, message) => {
- message.channel.startTyping();
- try {
- sfw.lizard().then((json) => {
- message.channel.send(json.url)
- message.channel.stopTyping();
- });
- } catch (err) {
- client.logger.error("lizard.js: " + err);
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`)
- message.channel.stopTyping();
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "lizard",
- category: "Image",
- description: "Sends pictures of lizards.",
- usage: "lizard"
-};
diff --git a/src/commands/modlogs.js b/src/commands/modlogs.js
deleted file mode 100644
index 3c0c2c0..0000000
--- a/src/commands/modlogs.js
+++ /dev/null
@@ -1,28 +0,0 @@
-exports.run = async (client, message) => {
- const settings = message.settings;
-
- if (!client.settings.has(message.guild.id)) client.settings.set(message.guild.id, {});
-
- if (message.channel.name !== settings.modlogsChannel) {
- client.settings.set(message.guild.id, message.channel.name, "modlogsChannel")
- message.channel.send(`<:success:466995111885144095> Mod logs will now be displayed in \`${message.channel.name}\``);
- } else {
- client.settings.set(message.guild.id, "off", "modlogsChannel")
- message.channel.send(`<:success:466995111885144095> Mod logging disabled.`);
- }
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Administrator",
- requiredPerms: []
-};
-
-exports.help = {
- name: "modlogs",
- category: "Configure",
- description: "Enables mod action logging in your server.",
- usage: "modlogs **OR** modlogs off"
-};
diff --git a/src/commands/modrole.js b/src/commands/modrole.js
deleted file mode 100644
index 817d89a..0000000
--- a/src/commands/modrole.js
+++ /dev/null
@@ -1,61 +0,0 @@
-exports.run = async (client, message, args) => {
-
- const settings = message.settings;
-
- if (!client.settings.has(message.guild.id)) {
- client.settings.set(message.guild.id, {});
- }
-
- var modRole = message.guild.roles.cache.get(settings.modRole)
-
- if (!args[0]) {
- if(!modRole) {
- return message.channel.send(
- "<:error:466995152976871434> There is no mod role set for this server. Please set one using `" + message.settings.prefix + "modrole `"
- )
- } else {
- message.channel.send(`The current mod role is: \`${modRole.name}\``)
- }
-
- } else {
- const joinedValue = args.join(" ");
- if (joinedValue.length < 1) {
- return message.channel.send(
- `<:error:466995152976871434> You didn't specify a role. Usage: \`${client.commands.get(`modrole`).help.usage}\``
- );
- };
-
- if (settings.modRole != "None set" && joinedValue === modRole.name) {
- return message.channel.send(
- "<:error:466995152976871434> The mod role is already set to that!"
- );
- };
-
- let role = client.findRole(joinedValue, message);
-
- if (!role) {
- return message.channel.send(`<:error:466995152976871434> That role doesn't seem to exist. Try again!`);
- };
-
- client.settings.set(message.guild.id, role.id, "modRole");
-
- message.channel.send(
- `<:success:466995111885144095> The mod role has been set to \`${role.name}\`
- `);
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Administrator",
- requiredPerms: []
-};
-
-exports.help = {
- name: "modrole",
- category: "Configure",
- description: "Sets the mod role for this server.",
- usage: "modrole "
-};
\ No newline at end of file
diff --git a/src/commands/msearch.js b/src/commands/msearch.js
deleted file mode 100644
index 876da31..0000000
--- a/src/commands/msearch.js
+++ /dev/null
@@ -1,39 +0,0 @@
-exports.run = (client, message, args) => {
- if (!args[0])
- return message.channel.send(
- `<:error:466995152976871434> No username provided. Usage: \`${client.commands.get(``).help.usage}\``
- );
- var mlist = "";
- var count = 0;
- client.searchForMembers(message.guild, args[0]).forEach((member) => {
- if (member) {
- mlist += `\`${member.user.tag}\``;
- count = count + 1;
- }
- mlist += "**, **";
- });
- mlist = mlist.substring(0, mlist.length - 6);
-
- var mlist1 = `Found ${count} users:\n` + mlist;
-
- if (!mlist1) {
- return message.channel.send("<:error:466995152976871434> No users found!");
- }
-
- message.channel.send(mlist1);
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "msearch",
- category: "Utility",
- description: "Search for server members.",
- usage: "msearch [user]"
-};
\ No newline at end of file
diff --git a/src/commands/mute.js b/src/commands/mute.js
deleted file mode 100644
index a52e7c5..0000000
--- a/src/commands/mute.js
+++ /dev/null
@@ -1,114 +0,0 @@
-exports.run = async (client, message, [args, ...reason], level) => {
- const settings = message.settings;
-
- if(!args) {
- return message.channel.send("<:error:466995152976871434> Who am I meant to mute?")
- }
- let user = message.mentions.members.first();
- let users;
- if (!user) {
- users = client.searchForMembers(message.guild, args);
- if (users.length > 1)
- return message.channel.send(
- "<:error:466995152976871434> Found multiple users! Please be more specific or mention the user instead."
- );
- else if (users.length == 0)
- return message.channel.send(
- "<:error:466995152976871434> That user doesn't seem to exist. Try again!"
- );
- user = users[0];
- };
-
- if (user.user.id === message.guild.ownerID) {
- return message.channel.send("<:error:466995152976871434> You can't mute the owner!")
- };
-
- let moderator = message.guild.member(message.author)
- if (message.settings.mutedRole.position >= moderator.roles.highest.position && level < 2) {
- return message.channel.send(
- "<:error:466995152976871434> The muted role is positioned above the moderator role! Please move the muted role below the moderator role."
- );
- };
- if (user.roles.highest.position >= moderator.roles.highest.position && moderator.user.id !== message.guild.ownerID) {
- return message.channel.send(
- `<:error:466995152976871434> You can't mute people who have a higher role than you!`
- );
- };
-
- let bot = message.guild.member(client.user)
-
- if (user.roles.highest.position >= bot.roles.highest.position) {
- return message.channel.send(
- `<:error:466995152976871434> I can't mute people who have a higher role than me!`
- );
- }
-
- var role = message.guild.roles.cache.get(settings.mutedRole);
-
- if (!role) {
- return message.channel.send(
- "<:error:466995152976871434> There is no muted role set for this server. Please set one using `" + message.settings.prefix + "mutedrole ` before using this command."
- );
- };
-
- if (bot.roles.highest.position <= role.position) {
- return message.channel.send(
- "<:error:466995152976871434> The muted role is above my highest role! Please move the muted role below my highest role."
- );
- };
-
- message.guild.channels.cache.forEach(async (channel, id) => {
- await channel.updateOverwrite(role, {
- SEND_MESSAGES: false,
- ADD_REACTIONS: false
- });
- });
-
- if (user.roles.cache.has(role.id)) {
- return message.channel.send("<:error:466995152976871434> They're already muted!")
- }
-
- await user.roles.add(role.id);
- message.channel.send(`<:success:466995111885144095> Muted \`${user.user.tag}\``)
-
- var muteReason = reason.join(" ");
-
- if(muteReason.length == 0) {
- muteReason = "**No reason provided.**"
- }
-
- if (settings.modlogsChannel !== "off") {
- const channel = message.guild.channels.cache.find(
- channel => channel.name === settings.modlogsChannel
- );
-
- if (channel) {
- let embed = new Discord.MessageEmbed();
- embed.setColor("#a652bb");
- embed.setAuthor("User muted!", user.user.avatarURL({format: "png", dynamic: true, size: 2048}));
- embed.setDescription(
- `• User: ${user} (${user.user.id})\n• Mod: ${message.author} (${message.author.id})\n• Reason: ${muteReason}`
- );
- try {
- channel.send(embed);
- } catch (err) {
- // probably no permissions to send messages/embeds there
- }
- }
- }
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Moderator",
- requiredPerms: ["MANAGE_ROLES", "MANAGE_CHANNELS"]
-};
-
-exports.help = {
- name: "mute",
- category: "Moderation",
- description: "Prevents the specified user from typing.",
- usage: "mute [member] "
-};
diff --git a/src/commands/mutedrole.js b/src/commands/mutedrole.js
deleted file mode 100644
index 1757efd..0000000
--- a/src/commands/mutedrole.js
+++ /dev/null
@@ -1,61 +0,0 @@
-exports.run = async (client, message, args) => {
-
- const settings = message.settings;
-
- if (!client.settings.has(message.guild.id)) {
- client.settings.set(message.guild.id, {});
- }
-
- var mutedRole = message.guild.roles.cache.get(settings.mutedRole)
-
- if (!args[0]) {
- if(!mutedRole) {
- return message.channel.send(
- "<:error:466995152976871434> There is no muted role set for this server. Please set one using `" + message.settings.prefix + "mutedrole `"
- )
- } else {
- message.channel.send(`The current muted role is: \`${mutedRole.name}\``)
- }
-
- } else {
- const joinedValue = args.join(" ");
- if (joinedValue.length < 1) {
- return message.channel.send(
- `<:error:466995152976871434> You didn't specify a role. Usage: \`${client.commands.get(`mutedrole`).help.usage}\``
- );
- };
-
- if (settings.mutedRole != "None set" && joinedValue === mutedRole.name) {
- return message.channel.send(
- "<:error:466995152976871434> The muted role is already set to that!"
- );
- };
-
- let role = client.findRole(joinedValue, message);
-
- if (!role) {
- return message.channel.send(`<:error:466995152976871434> That role doesn't seem to exist. Try again!`);
- };
-
- client.settings.set(message.guild.id, role.id, "mutedRole");
-
- message.channel.send(
- `<:success:466995111885144095> The muted role has been set to \`${role.name}\`
- `);
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Administrator",
- requiredPerms: []
-};
-
-exports.help = {
- name: "mutedrole",
- category: "Configure",
- description: "Sets the muted role for this server.",
- usage: "mutedrole [role]"
-};
diff --git a/src/commands/neko.js b/src/commands/neko.js
deleted file mode 100644
index 7ce0d6b..0000000
--- a/src/commands/neko.js
+++ /dev/null
@@ -1,30 +0,0 @@
-const API = require('nekos.life');
-const {sfw} = new API();
-exports.run = async (client, message) => {
- message.channel.startTyping();
- try {
- sfw.neko().then((json) => {
- message.channel.send(json.url);
- message.channel.stopTyping();
- });
- } catch (err) {
- client.logger.error("neko.js: " + err);
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`)
- message.channel.stopTyping();
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["catgirl"],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "neko",
- category: "Image",
- description: "Sends you pictures of catgirls.",
- usage: "neko"
-};
diff --git a/src/commands/nekogif.js b/src/commands/nekogif.js
deleted file mode 100644
index 0df6917..0000000
--- a/src/commands/nekogif.js
+++ /dev/null
@@ -1,30 +0,0 @@
-const API = require('nekos.life');
-const {sfw} = new API();
-exports.run = async (client, message) => {
- message.channel.startTyping();
- try {
- sfw.nekoGif().then((json) => {
- message.channel.send(json.url);
- message.channel.stopTyping();
- });
- } catch (err) {
- client.logger.error("nekogif.js: " + err);
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`)
- message.channel.stopTyping();
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["catgirlgif"],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "nekogif",
- category: "Image",
- description: "Sends you gifs of catgirls.",
- usage: "nekogif"
-};
diff --git a/src/commands/nowplaying.js b/src/commands/nowplaying.js
deleted file mode 100644
index e94f71a..0000000
--- a/src/commands/nowplaying.js
+++ /dev/null
@@ -1,44 +0,0 @@
-const Discord = require("discord.js");
-exports.run = async (client, message) => {
- let guild = client.music.getGuild(message.guild.id);
-
- if(guild.queue.length < 1) {
- return message.channel.send("<:error:466995152976871434> Nothing is playing.");
- }
-
- var song = guild.queue[0];
- var elapsedTime = client.createTimestamp(guild.dispatcher.streamTime / 1000);
- var timestamp;
-
- if(song.duration == 0) {
- timestamp = "`[LIVE]`";
- } else {
- timestamp = `\`[${elapsedTime + "/" + client.createTimestamp(song.duration)}]\``;
- };
-
- embed = new Discord.MessageEmbed();
- embed.setTitle("Now playing:")
- embed.setThumbnail(song.thumbnail)
- embed.setColor(client.embedColour(message));
- embed.setDescription(`**[${song.title}](https://www.youtube.com/watch?v=${song.id})**`)
- embed.addField("Channel:", song.author, true)
- embed.addField("Time:", timestamp, true)
- embed.setFooter("Requested by " + song.requestedBy.tag, song.requestedBy.avatarURL({format: "png", dynamic: true, size: 2048}))
-
- message.channel.send(embed)
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: ["np"],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "nowplaying",
- category: "Music",
- description: "Shows details about the currently playing song.",
- usage: "nowplaying"
-};
diff --git a/src/commands/owoify.js b/src/commands/owoify.js
deleted file mode 100644
index 9587a6f..0000000
--- a/src/commands/owoify.js
+++ /dev/null
@@ -1,35 +0,0 @@
-// totally not stolen from https://github.com/GmdDjca/Hitomi-Manaka
-exports.run = (client, message, args) => {
- if (!args[0]) {
- return message.channel.send(`<:error:466995152976871434> pwease incwude some text fow me to owoify UwU`)
- }
- const faces = ['(・`ω´・)', 'x3', 'owo', 'UwU', '>w<', '^w^']
- owoified = `${args.join(' ')}`.replace(/(?:r|l)/g, 'w')
- owoified = owoified.replace(/(?:R|L)/g, 'W')
- owoified = owoified.replace(/n([aeiou])/g, 'ny$1')
- owoified = owoified.replace(/N([aeiou])/g, 'Ny$1')
- owoified = owoified.replace(/N([AEIOU])/g, 'Ny$1')
- owoified = owoified.replace(/ove/g, 'uv')
- owoified = owoified.replace(/!+/g, ' ' + faces[~~(Math.random() * faces.length)] + ' ')
-
- if(owoified.length > 2000) {
- owoified = owoified.slice(0, -Math.abs(owoified.length - 2000))
- };
-
-message.channel.send(owoified)
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "owoify",
- category: "Fun",
- description: "Makes nyowmal tewxt owo'ed x3",
- usage: "owoify [message]"
-};
diff --git a/src/commands/pat.js b/src/commands/pat.js
deleted file mode 100644
index fee469b..0000000
--- a/src/commands/pat.js
+++ /dev/null
@@ -1,69 +0,0 @@
-const API = require('nekos.life');
-const {sfw} = new API();
-exports.run = async (client, message, args) => {
- if(!args[0]) {
- return message.channel.send(`<:error:466995152976871434> You didn't say who you wanted to pat! Usage: \`${client.commands.get(`pat`).help.usage}\``)
- };
-
- var people = "";
-
- for (var i = 0; i < args.length; i++) {
- var user = client.getUserFromMention(args[i])
- if (user) {
- user = message.guild.members.cache.get(user.id).displayName;
- } else {
- users = client.searchForMembers(message.guild, args[i]);
- if (users.length > 1)
- return message.channel.send(
- "<:error:466995152976871434> Found multiple users for `" + args[i] + "`, Please be more specific or mention the user instead."
- );
- else if (users.length == 0)
- return message.channel.send(
- "<:error:466995152976871434> That user doesn't seem to exist. Try again!"
- );
- user = users[0].displayName;
- };
- if(i+1 == args.length && args.length > 1) {
- people += `**and** ${user}!`
- } else if(args.length < 2) {
- people += `${user}!`;
- } else if(args.length == 2 && i == 0) {
- people += `${user} `;
- } else {
- people += `${user}, `;
- };
- };
-
-
-
- message.channel.startTyping();
- try {
- sfw.pat().then((json) => {
- embed = new Discord.MessageEmbed();
- embed.setImage(json.url)
- embed.setColor(client.embedColour(message));
- embed.setDescription(`**${message.guild.members.cache.get(message.author.id).displayName}** patted **${people}**`)
- message.channel.send(embed)
- message.channel.stopTyping();
- });
- } catch (err) {
- client.logger.error("pat.js: " + err);
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`)
- message.channel.stopTyping();
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: ["headpat"],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "pat",
- category: "Action",
- description: "pat someone!",
- usage: "pat [@user/user] (you can pat as many people as you want!)"
-};
diff --git a/src/commands/pause.js b/src/commands/pause.js
deleted file mode 100644
index 2816baf..0000000
--- a/src/commands/pause.js
+++ /dev/null
@@ -1,30 +0,0 @@
-exports.run = (client, message, args, level) => {
- let guild = client.music.getGuild(message.guild.id);
- if(guild.queue.length < 1) {
- return message.channel.send("<:error:466995152976871434> Nothing is playing.");
- };
-
- guild.playing = false;
- guild.paused = true;
- guild.dispatcher.pause();
- message.channel.send("<:pause:467639357961142273> Playback paused!");
-
-
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Moderator",
- requiredPerms: ["CONNECT", "SPEAK"]
-};
-
-exports.help = {
- name: "pause",
- category: "Music",
- description: "Pauses music playback.",
- usage: "pause"
-};
-
-
diff --git a/src/commands/permlevel.js b/src/commands/permlevel.js
deleted file mode 100644
index 5d41034..0000000
--- a/src/commands/permlevel.js
+++ /dev/null
@@ -1,19 +0,0 @@
-exports.run = async (client, message, args, level) => {
- const friendly = client.config.permLevels.find(l => l.level === level).name;
- message.reply(`Your permission level is: ${level} - ${friendly}`);
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["plevel"],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "permlevel",
- category: "Utility",
- description: "Tells you your permission level for that server.",
- usage: "permlevel"
-};
diff --git a/src/commands/ping.js b/src/commands/ping.js
deleted file mode 100644
index 6f6d674..0000000
--- a/src/commands/ping.js
+++ /dev/null
@@ -1,21 +0,0 @@
-exports.run = async (client, message) => {
- const msg = await message.channel.send("⏱️ Please wait...");
- msg.edit(
- `:ping_pong: Pong! Latency is ${msg.createdTimestamp - message.createdTimestamp}ms, API Latency is ${Math.round(client.ws.ping)}ms`
- );
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "ping",
- category: "Utility",
- description: "Displays bot latency in miliseconds.",
- usage: "ping"
-};
diff --git a/src/commands/play.js b/src/commands/play.js
deleted file mode 100644
index d9c8866..0000000
--- a/src/commands/play.js
+++ /dev/null
@@ -1,33 +0,0 @@
-const util = require("util")
-const Discord = require("discord.js")
-
-module.exports.run = (client, message, args, level) =>{
- if(!args[0])
- {
- message.channel.send(`<:error:466995152976871434> You didn't give me a song to play! Usage: \`${client.commands.get(`play`).help.usage}\``);
-
- return;
- }
-
- let voiceChannel = message.member.voice.channel;
- if(!voiceChannel) return message.channel.send('<:error:466995152976871434> You need to be in a voice channel to use this command!');
-
- message.channel.send(`🔎 searching YouTube for \`${args.join(" ")}\``);
-
- client.music.play(message, args.join(" "));
-}
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: ["p"],
- permLevel: "User",
- requiredPerms: ["CONNECT", "SPEAK"]
-};
-
-exports.help = {
- name: "play",
- category: "Music",
- description: "Plays a song.",
- usage: "play [youtube-url] **OR** play [song-name]"
-};
diff --git a/src/commands/poke.js b/src/commands/poke.js
deleted file mode 100644
index 07c48bc..0000000
--- a/src/commands/poke.js
+++ /dev/null
@@ -1,69 +0,0 @@
-const API = require('nekos.life');
-const {sfw} = new API();
-exports.run = async (client, message, args) => {
- if(!args[0]) {
- return message.channel.send(`<:error:466995152976871434> You didn't say who you wanted to poke! Usage: \`${client.commands.get(`poke`).help.usage}\``)
- };
-
- var people = "";
-
- for (var i = 0; i < args.length; i++) {
- var user = client.getUserFromMention(args[i])
- if (user) {
- user = message.guild.members.cache.get(user.id).displayName;
- } else {
- users = client.searchForMembers(message.guild, args[i]);
- if (users.length > 1)
- return message.channel.send(
- "<:error:466995152976871434> Found multiple users for `" + args[i] + "`, Please be more specific or mention the user instead."
- );
- else if (users.length == 0)
- return message.channel.send(
- "<:error:466995152976871434> That user doesn't seem to exist. Try again!"
- );
- user = users[0].displayName;
- };
- if(i+1 == args.length && args.length > 1) {
- people += `**and** ${user}!`
- } else if(args.length < 2) {
- people += `${user}!`;
- } else if(args.length == 2 && i == 0) {
- people += `${user} `;
- } else {
- people += `${user}, `;
- };
- };
-
-
-
- message.channel.startTyping();
- try {
- sfw.poke().then((json) => {
- embed = new Discord.MessageEmbed();
- embed.setImage(json.url)
- embed.setColor(client.embedColour(message));
- embed.setDescription(`**${message.guild.members.cache.get(message.author.id).displayName}** poked **${people}**`)
- message.channel.send(embed)
- message.channel.stopTyping();
- });
- } catch (err) {
- client.logger.error("poke.js: " + err);
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`)
- message.channel.stopTyping();
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "poke",
- category: "Action",
- description: "poke someone!",
- usage: "poke [@user/user] (you can poke as many people as you want!)"
-};
diff --git a/src/commands/prefix.js b/src/commands/prefix.js
deleted file mode 100644
index 1d72e74..0000000
--- a/src/commands/prefix.js
+++ /dev/null
@@ -1,30 +0,0 @@
-exports.run = async (client, message, args) => {
- const settings = message.settings;
-
- if (!client.settings.has(message.guild.id)) client.settings.set(message.guild.id, {});
-
- if (args[0]) {
- const joinedValue = args.join(" ");
- if (joinedValue === settings.prefix) return message.channel.send("<:error:466995152976871434> The prefix is already set to that!");
- if (!client.settings.has(message.guild.id)) client.settings.set(message.guild.id, {});
- client.settings.set(message.guild.id, joinedValue, "prefix");
- message.channel.send(`<:success:466995111885144095> Set the prefix to \`${joinedValue}\``);
- } else {
- message.channel.send(`The current prefix is: \`${settings.prefix}\``)
- }
-}
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Administrator",
- requiredPerms: []
-};
-
-exports.help = {
- name: "prefix",
- category: "Configure",
- description: "Sets the prefix for this server.",
- usage: "prefix [prefix]"
-};
diff --git a/src/commands/pronoun.js b/src/commands/pronoun.js
deleted file mode 100644
index 0d4b36a..0000000
--- a/src/commands/pronoun.js
+++ /dev/null
@@ -1,36 +0,0 @@
-const pronouns = require ("../../resources/other/pronouns.json");
-exports.run = async (client, message, args) => {
- var output = "";
- if(!args[0]) {
- for (var key of Object.keys(pronouns)) {
- output += `${key}, `
- };
- return message.channel.send(`__**Pronouns:**__\n${output.slice(0, -2)}`);
- } else {
- if(args.join(" ").toLowerCase() == "attack helicopter" || args.join(" ").toLowerCase() == "apache attack helicopter" || args.join(" ").toLowerCase() == "apache") {
- return message.channel.send({
- files: [new Discord.MessageAttachment("./resources/images/attackhelicopter.jpg")]
- });
- };
- output = pronouns[args.join(" ").toLowerCase()];
- if(!output) {
- return message.channel.send("<:error:466995152976871434> No results for that query.");
- };
- return message.channel.send(`__**Example sentences using ${output.name}:**__\n${output.examples}`);
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["pronouns"],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "pronoun",
- category: "Fun",
- description: "Gives you information on how to use the specified pronoun.",
- usage: "pronoun [pronoun]"
-};
diff --git a/src/commands/purge.js b/src/commands/purge.js
deleted file mode 100644
index 79cf320..0000000
--- a/src/commands/purge.js
+++ /dev/null
@@ -1,60 +0,0 @@
-exports.run = async (client, message, args, level) => {
- const settings = message.settings;
-
- if(message.channel.name === settings.chatlogsChannel) {
- return message.channel.send("<:error:466995152976871434> Can't purge logs.")
- }
-
- if(message.channel.name === settings.modlogsChannel) {
- return message.channel.send("<:error:466995152976871434> Can't purge logs.")
- }
- const amount = !!parseInt(message.content.split(' ')[1]) ? parseInt(message.content.split(' ')[1]) : parseInt(message.content.split(' ')[2])
- if(amount > 100) {
- return message.channel.send("<:error:466995152976871434> Can only purge a maximum of 100 messages!")
- }
-
- if (!amount) return message.channel.send(
- '<:error:466995152976871434> You didn\'t tell me how many messages to purge. Usage: \`' + client.commands.get(`purge`).help.usage + "`"
- );
-
- await message.delete().catch(O_o => {});
-
- message.channel.messages.fetch({
- limit: amount,
- }).then((messages) => {
- message.channel.bulkDelete(messages, true).catch(console.error);
- message.channel.send(`<:success:466995111885144095> Purged ${amount} messages!`).then(m => m.delete({timeout: 5000}));
- });
-
- if (settings.modlogsChannel !== "off") {
- const channel = message.guild.channels.cache.find(
- channel => channel.name === settings.modlogsChannel
- );
-
- if (channel) {
- let embed = new Discord.MessageEmbed();
- embed.setColor("#a62019");
- embed.setAuthor(`${amount} messages purged!`, message.author.avatarURL({format: "png", dynamic: true, size: 2048}));
- embed.setDescription(`• Channel: ${message.channel.name} (${message.channel.id})\n• Mod: ${message.author} (${message.author.id})\n• Amount: \`${amount}\``)
- try {
- channel.send({ embed });
- } catch (err) {
- };
- };
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Moderator",
- requiredPerms: ["MANAGE_MESSAGES"]
-};
-
-exports.help = {
- name: "purge",
- category: "Moderation",
- description: "Bulk deletes messages. **cannot delete messages older than 14 days.**",
- usage: "purge [amount]"
-};
diff --git a/src/commands/queue.js b/src/commands/queue.js
deleted file mode 100644
index 0bdc87e..0000000
--- a/src/commands/queue.js
+++ /dev/null
@@ -1,183 +0,0 @@
-'use strict';
-
-const Discord = require("discord.js");
-exports.run = (client, message, args) => {
- var queue = client.music.getGuild(message.guild.id).queue;
-
- if(queue.length < 1) {
- return message.channel.send("<:error:466995152976871434> Nothing is playing.");
- }
-
- let lists = [];
-
- function generateList(start, number) {
- var list = "";
- var timestamp;
- var livestream;
-
- if(start == 1 && queue.length == 1) {
- return ["There's nothing else waiting to be played!", 1];
- }
-
- if(number == 1 && queue.length + 1 < start) {
- return false;
- };
-
- let q = queue.slice(start);
-
- let i = 0;
-
- for(i = 0; i < q.length; i++) {
- let song = q[i];
-
- if(song.duration == 0) {
- timestamp = "LIVE";
- livestream = true;
- } else {
- timestamp = client.createTimestamp(song.duration);
- };
-
- let aaa = list + `\`${(i + 1) + start - 1}:\` **[${song.title}](https://www.youtube.com/watch?v=${song.id})** added by ${song.requestedBy} \`[${timestamp}]\`\n`;
-
- if(aaa.length > 1024) {
- return [list, start + i - 1];
- } else {
- list = aaa;
- }
-
- //totalDuration = totalDuration + song.duration;
- };
-
- return [list, start + i + 1];
- };
-
- let songsInQueue = queue.length - 1;
- let songsInQueueEnglish = "song";
- let timeRemaining = 0;
-
- function generatePage(list, page) {
- if(!list || list == "") {
- return false;
- }
-
- var embed = new Discord.MessageEmbed();
- embed.setTitle(`Queue for: ${message.guild.name}`);
- embed.setColor(client.embedColour(message));
-
- var elapsedTime = client.music.getGuild(message.guild.id).dispatcher.streamTime / 1000
- var totalDuration = queue[0].duration - elapsedTime;
-
- let timeRemaining = "";
-
- for(let i = 1; i < queue.length; i++) {
- let b = queue[i];
-
- if(b.duration == 0) {
- timeRemaining = "∞";
-
- break;
- }
-
- totalDuration += b.duration;
- }
-
- if(timeRemaining == "") {
- let queueDuration = client.createTimestamp(totalDuration);
-
- timeRemaining = queueDuration;
- }
-
- let timestamp;
-
- if(queue[0].duration == 0) {
- timestamp = "LIVE";
- livestream = true;
- } else {
- timestamp = client.createTimestamp(elapsedTime) + '/' + client.createTimestamp(queue[0].duration);
- };
-
- embed.addField(`Now playing:`, `**[${queue[0].title}](https://www.youtube.com/watch?v=${queue[0].id})** added by ${queue[0].requestedBy} \`[${timestamp}]\``)
-
- embed.addField(`Up next:`, list);
-
- if(songsInQueue > 1 || songsInQueue == 0) {
- songsInQueueEnglish = "songs";
- }
-
- embed.setFooter(`Page ${page}/${lists.length} | ${songsInQueue + " " + songsInQueueEnglish} in queue | ${timeRemaining} time remaining`);
-
- return embed;
- };
-
- var myMessage = null;
-
- function displayPage(number) {
- let page = generatePage(lists[number - 1], number);
-
- if(page) {
- if(myMessage) {
- myMessage.edit(page);
- } else {
- myMessage = message.channel.send(page);
- }
-
- return true;
- } else {
- return false;
- }
- };
-
- function aFunction(start) {
- // start - index of song, which we should start with
- // end - index of song, which we ended with
-
- let [list, end] = generateList(start, lists.length + 1);
-
- if(list && list != "") {
- lists.push(list);
-
- if(queue[end + 1]) {
- aFunction(end + 1);
- }
- }
- };
-
- aFunction(1);
-
- let page = 1;
-
- if(args[0]) {
- let userPage = Number(args[0]);
-
- if(userPage) {
- page = userPage;
- } else {
- return message.channel.send(
- `<:error:466995152976871434> Invalid page. Usage: \`${client.commands.get(`queue`).help.usage}\``
- );
- }
- };
-
- if(displayPage(page)) {
-
- } else {
- return message.channel.send(
- `<:error:466995152976871434> Page ${page} doesn't exist!`
- );
- }
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "queue",
- category: "Music",
- description: "Displays what songs are in the queue.",
- usage: "queue "
-};
diff --git a/src/commands/raidmode.js b/src/commands/raidmode.js
deleted file mode 100644
index 68a70ec..0000000
--- a/src/commands/raidmode.js
+++ /dev/null
@@ -1,70 +0,0 @@
-const Discord = require("discord.js")
-exports.run = async (client, message, args, level) => {
-
- const settings = message.settings;
- const defaults = client.config.defaultSettings;
- const overrides = client.settings.get(message.guild.id);
- if (!client.settings.has(message.guild.id)) client.settings.set(message.guild.id, {});
-
- var raidToggle;
- var embColour;
- var mutedRole = message.guild.roles.cache.get(settings.mutedRole)
-
- if(!mutedRole) {
- return message.channel.send(
- "<:error:466995152976871434> This command requires a muted role to be set! Please ask an admin or the owner to set this with `" + message.settings.prefix + "mutedrole `"
- )
- }
- if(args[0] == "strict") {
- client.settings.set(message.guild.id, "on", "raidModeStrict");
- client.settings.set(message.guild.id, "on", "raidMode");
- message.channel.send(`<:success:466995111885144095> Strict raid mode enabled! New users will now be automatically kicked.`);
- raidToggle = "Strict raid mode activated!"
- embColour = "#777B7E"
- } else {
- if (settings.raidMode === "off") {
- client.settings.set(message.guild.id, "on", "raidMode")
- message.channel.send(`<:success:466995111885144095> Raid mode enabled! New users will now be automatically muted.`);
- raidToggle = "Raid mode activated!"
- embColour = "#777B7E"
- } else {
- client.settings.set(message.guild.id, "off", "raidMode")
- client.settings.set(message.guild.id, "off", "raidModeStrict");
- message.channel.send(`<:success:466995111885144095> Raid mode disabled.`);
- raidToggle = "Raid mode deactivated!"
- embColour = "#48494b"
- };
-};
- if (settings.modlogsChannel !== "off") {
- const channel = message.guild.channels.cache.find(
- channel => channel.name === settings.modlogsChannel
- );
-
- if (channel) {
- let embed = new Discord.MessageEmbed();
- embed.setColor(embColour);
- embed.setAuthor(raidToggle, message.author.avatarURL({format: "png", dynamic: true, size: 2048}));
- embed.setDescription(`• Mod: ${message.author} (${message.author.id})`)
- try {
- channel.send({ embed });
- } catch (err) {
- // probably no permissions to send messages/embeds there
- }
- }
- }
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Administrator",
- requiredPerms: ["MANAGE_ROLES", "KICK_MEMBERS"]
-};
-
-exports.help = {
- name: "raidmode",
- category: "Moderation",
- description: "Enables/disables raid mode in your server, which automatically mutes new members. Strict raidmode automatically kicks new members.",
- usage: "raidmode **OR** raidmode strict"
-};
diff --git a/src/commands/randurban.js b/src/commands/randurban.js
deleted file mode 100644
index 1a6a42b..0000000
--- a/src/commands/randurban.js
+++ /dev/null
@@ -1,41 +0,0 @@
-const urban = require("urban");
-exports.run = (client, message) => {
- urban.random().first(json => {
- if(message.channel.nsfw === false) return message.channel.send(
- "<:error:466995152976871434> This command can only be executed in channels marked as NSFW!"
- );
- if(json.definition.length > 2000) return message.channel.send(
- `<:error:466995152976871434> Definition cannot exceed 2000 characters! Use this link instead: ${json.permalink}`
- );
- if(json.example.length > 2000) return message.channel.send(
- "<:error:466995152976871434> Example cannot exceed 2000 characters!"
- );
-
- embed = new Discord.MessageEmbed()
- .setTitle(json.word)
- .setURL(json.permalink)
- .setColor("#EFFF00")
- .setDescription(json.definition || "None")
- .addField("Example", json.example || "None")
- .addField("Upvotes", json.thumbs_up, true)
- .addField("Downvotes", json.thumbs_down, true)
- .setFooter(`Submitted by ${json.author}`)
- message.channel.send(embed);
-
- });
-}
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["rurban"],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "randurban",
- category: "Fun",
- description: "Grabs a random definition from the Urban Dictonary.",
- usage: "randurban"
-};
diff --git a/src/commands/rate.js b/src/commands/rate.js
deleted file mode 100644
index d4f0eac..0000000
--- a/src/commands/rate.js
+++ /dev/null
@@ -1,36 +0,0 @@
-exports.run = async (client, message, args) => {
- if (!args[0])
- return message.channel.send(
- `<:error:466995152976871434> What am I meant to rate? Usage: \`${client.commands.get(`rate`).help.usage}\``
- );
-var rating = [
- "0/10",
- "1/10",
- "2/10",
- "3/10",
- "4/10",
- "5/10",
- "6/10",
- "7/10",
- "8/10",
- "9/10",
- "10/10"
-];
- let mess = rating.random();
- message.channel.send(`<:star:618393201501536258> I give ${args.join(" ")} a **${mess}**`);
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "rate",
- category: "Fun",
- description: "Gives something a rating from 0-10",
- usage: "rate [thing]"
-};
\ No newline at end of file
diff --git a/src/commands/reload.js b/src/commands/reload.js
deleted file mode 100644
index 8cefd15..0000000
--- a/src/commands/reload.js
+++ /dev/null
@@ -1,28 +0,0 @@
-exports.run = async (client, message, args) => {// eslint-disable-line no-unused-vars
- if (!args || args.length < 1) return message.channel.send(
- `<:error:466995152976871434> You must provide a command to reload! Usage: \`${client.commands.get(`reload`).help.usage}\``
- );
-
- let response = await client.unloadCommand(args[0]);
- if (response) return message.channel.send(`<:error:466995152976871434> Error unloading: ${response}`);
-
- response = client.loadCommand(args[0]);
- if (response) return message.channel.send(`<:error:466995152976871434> Error loading: ${response}`);
-
- message.channel.send(`<:success:466995111885144095> \`${args[0]}\` has been reloaded!`);
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "Developer",
- requiredPerms: []
-};
-
-exports.help = {
- name: "reload",
- category: "Owner",
- description: "Reloads the specified command.",
- usage: "reload [command]"
-};
diff --git a/src/commands/removesong.js b/src/commands/removesong.js
deleted file mode 100644
index d576c7d..0000000
--- a/src/commands/removesong.js
+++ /dev/null
@@ -1,49 +0,0 @@
-const util = require("util")
-const Discord = require("discord.js")
-
-module.exports.run = (client, message, args, level) =>{
- var queue = client.music.getGuild(message.guild.id).queue;
-
- if(queue.length < 2) {
- return message.channel.send(`<:error:466995152976871434> Not enough songs are in the queue for this command to work!`);
- }
-
- if(!args[0]) {
- return message.channel.send(`<:error:466995152976871434> You didn't tell me what song to remove! Usage: \`${client.commands.get(`removesong`).help.usage}\``);
- };
-
- var input = +args[0];
-
- if(isNaN(input) == true) {
- return message.channel.send(`<:error:466995152976871434> That isn't a number! You need to tell me the songs position in the queue (1, 2, etc.)`);
- };
-
- if(input >= queue.length) {
- return message.channel.send("Invalid (too large)");
- };
-
- if(input < 1) {
- return message.channel.send("Invalid (too small)");
- };
-
- var songName = queue[input].title;
-
- queue.splice(input, 1);
-
- message.channel.send(`<:success:466995111885144095> Removed from queue: **${songName}**`);
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: ["rmsong"],
- permLevel: "Moderator",
- requiredPerms: ["SPEAK"]
-};
-
-exports.help = {
- name: "removesong",
- category: "Music",
- description: "Removes the specified song from the queue.",
- usage: "removesong [position]"
-};
diff --git a/src/commands/reset.js b/src/commands/reset.js
deleted file mode 100644
index ca8fe34..0000000
--- a/src/commands/reset.js
+++ /dev/null
@@ -1,30 +0,0 @@
-const Discord = require("discord.js")
-exports.run = async (client, message) => {
-
- if (!client.settings.has(message.guild.id)) client.settings.set(message.guild.id, {});
-
- const response = await client.awaitReply(message,
- "<:reboot:467216876938985482> This will clear the guild config and restore me to my default settings. Are you sure you want to do this?"
- );
- if (["y", "yes"].includes(response.toLowerCase())) {
- client.settings.set(message.guild.id, {});
- message.channel.send("<:success:466995111885144095> All settings have been restored to their default values.")
- } else {
- message.channel.send("<:success:466995111885144095> Action cancelled.")
- }
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Administrator",
- requiredPerms: []
-};
-
-exports.help = {
- name: "reset",
- category: "Configure",
- description: "Resets all settings to their default values.",
- usage: "reset"
-};
\ No newline at end of file
diff --git a/src/commands/restart.js b/src/commands/restart.js
deleted file mode 100644
index f3cf1a7..0000000
--- a/src/commands/restart.js
+++ /dev/null
@@ -1,27 +0,0 @@
-exports.run = async (client, message) => {// eslint-disable-line no-unused-vars
-
- // This actually shuts down the bot, you'll need to use something like pm2 to get it to restart
-
- await message.channel.send("<:reboot:467216876938985482> Restarting...");
-
- client.commands.forEach( async cmd => {
- await client.unloadCommand(cmd);
- });
-
- process.exit();
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "Developer",
- requiredPerms: []
-};
-
-exports.help = {
- name: "restart",
- category: "Owner",
- description: "Restarts the bot.",
- usage: "restart"
-};
diff --git a/src/commands/resume.js b/src/commands/resume.js
deleted file mode 100644
index 9c63f87..0000000
--- a/src/commands/resume.js
+++ /dev/null
@@ -1,28 +0,0 @@
-const Discord = require("discord.js")
-exports.run = (client, message, args, level) => {
- let guild = client.music.getGuild(message.guild.id);
- if(guild.queue.length < 1) {
- return message.channel.send("<:error:466995152976871434> Nothing is playing.");
- };
- guild.playing = true;
- guild.paused = false;
- guild.dispatcher.resume();
- message.channel.send("<:play:467216788187512832> Playback resumed!");
-
-
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: ["unpause"],
- permLevel: "Moderator",
- requiredPerms: ["SPEAK"]
-};
-
-exports.help = {
- name: "resume",
- category: "Music",
- description: "Unpauses music.",
- usage: "resume"
-};
\ No newline at end of file
diff --git a/src/commands/rip.js b/src/commands/rip.js
deleted file mode 100644
index d677655..0000000
--- a/src/commands/rip.js
+++ /dev/null
@@ -1,25 +0,0 @@
-var request = require('request');
-const Discord = require("discord.js")
-exports.run = (client, message) => {
- message.channel.startTyping();
- var r = request.get('http://mityurl.com/y/yKsQ/r', function (err, res, body) {
- var rip = r.uri.href
- message.channel.send(`>:] ${rip}`)
- message.channel.stopTyping();
- });
-}
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: []
- };
-
- exports.help = {
- name: "rip",
- category: "Fun",
- description: "nice >:]",
- usage: "`rip`"
- };
\ No newline at end of file
diff --git a/src/commands/rolecolour.js b/src/commands/rolecolour.js
deleted file mode 100644
index 31248b6..0000000
--- a/src/commands/rolecolour.js
+++ /dev/null
@@ -1,52 +0,0 @@
-exports.run = async (client, message, [colour, ...givenRole], query) => {
- let role = givenRole.join(" ");
-
- let gRole = client.findRole(role, message);
-
- if (!gRole) {
- return message.channel.send(`<:error:466995152976871434> That role doesn't seem to exist. Try again!`);
- };
-
- if(!colour.startsWith('#')) {
- colour = `#`+colour;
- }
- if(colour.length > 7) return message.channel.send(
- `<:error:466995152976871434> Colour has to be a hex code. Usage: \`${client.commands.get(`rolecolour`).help.usage}\``
- );
- if(colour.length < 7) return message.channel.send(
- `<:error:466995152976871434> Colour has to be a hex code. Usage: \`${client.commands.get(`rolecolour`).help.usage}\``
- );
-
- let moderator = message.guild.member(message.author)
- if (gRole.position >= moderator.roles.highest.position) {
- return message.channel.send(
- "<:error:466995152976871434> You cannot modify roles higher than your own!"
- );
- }
-
- var bot = message.guild.members.cache.get(client.user.id)
- if (gRole.position >= bot.roles.highest.position) {
- return message.channel.send(
- `<:error:466995152976871434> I cannot modify roles higher than my own!`
- );
- }
-
- await gRole.edit({color: colour})
- message.channel.send(
- `<:success:466995111885144095> The colour of the role \`${gRole.name}\` has been set to \`${colour}\``);
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: ["rolecolor"],
- permLevel: "Moderator",
- requiredPerms: ["MANAGE_ROLES"]
-};
-
-exports.help = {
- name: "rolecolour",
- category: "Utility",
- description: "Sets the colour of a role to the specified hex.",
- usage: "rolecolour [hex] [role]"
-};
diff --git a/src/commands/roleinfo.js b/src/commands/roleinfo.js
deleted file mode 100644
index 10d8c4d..0000000
--- a/src/commands/roleinfo.js
+++ /dev/null
@@ -1,75 +0,0 @@
-const Discord = require("discord.js");
-exports.run = async (client, message, args, level) => {
- if (!args[0])
- return message.channel.send(
- `<:error:466995152976871434> You didn't provide me with a role name or ID! Usage: \`${client.commands.get(`roleinfo`).help.usage}\``
- );
-
- let role = client.findRole(args.join(" "), message);
-
- if (!role) {
- return message.channel.send(`<:error:466995152976871434> That role doesn't seem to exist. Try again!`);
- };
-
- if(!role) {
- return message.channel.send(`<:error:466995152976871434> Role not found.`)
- }
-
- var permissions = "```";
- if(role.permissions.has("ADMINISTRATOR")) permissions += "ADMINISTRATOR, ";
- if(role.permissions.has("CREATE_INSTANT_INVITE")) permissions += "CREATE_INSTANT_INVITE, ";
- if(role.permissions.has("KICK_MEMBERS")) permissions += "KICK_MEMBERS, ";
- if(role.permissions.has("BAN_MEMBERS")) permissions += "BAN_MEMBERS, ";
- if(role.permissions.has("MANAGE_CHANNELS")) permissions += "MANAGE_CHANNELS, ";
- if(role.permissions.has("MANAGE_GUILD")) permissions += "MANAGE_GUILD, ";
- if(role.permissions.has("ADD_REACTIONS")) permissions += "ADD_REACTIONS, ";
- if(role.permissions.has("VIEW_AUDIT_LOG")) permissions += "VIEW_AUDIT_LOG, ";
- if(role.permissions.has("PRIORITY_SPEAKER")) permissions += "PRIORITY_SPEAKER, ";
- if(role.permissions.has("STREAM")) permissions += "STREAM, ";
- if(role.permissions.has("VIEW_CHANNEL")) permissions += "VIEW_CHANNEL, ";
- if(role.permissions.has("SEND_MESSAGES")) permissions += "SEND_MESSAGES, ";
- if(role.permissions.has("SEND_TTS_MESSAGES")) permissions += "SEND_TTS_MESSAGES, ";
- if(role.permissions.has("MANAGE_MESSAGES")) permissions += "MANAGE_MESSAGES, ";
- if(role.permissions.has("EMBED_LINKS")) permissions += "EMBED_LINKS, ";
- if(role.permissions.has("ATTACH_FILES")) permissions += "ATTACH_FILES, ";
- if(role.permissions.has("READ_MESSAGE_HISTORY")) permissions += "READ_MESSAGE_HISTORY, ";
- if(role.permissions.has("MENTION_EVERYONE")) permissions += "MENTION_EVERYONE, ";
- if(role.permissions.has("USE_EXTERNAL_EMOJIS")) permissions += "USE_EXTERNAL_EMOJIS, ";
- if(role.permissions.has("CONNECT")) permissions += "CONNECT, ";
- if(role.permissions.has("SPEAK")) permissions += "SPEAK, ";
- if(role.permissions.has("MUTE_MEMBERS")) permissions += "MUTE_MEMBERS, ";
- if(role.permissions.has("DEAFEN_MEMBERS")) permissions += "DEAFEN_MEMBERS, ";
- if(role.permissions.has("MOVE_MEMBERS")) permissions += "MOVE_MEMBERS, ";
- if(role.permissions.has("USE_VAD")) permissions += "USE_VAD, ";
- if(role.permissions.has("CHANGE_NICKNAME")) permissions += "CHANGE_NICKNAME, ";
- if(role.permissions.has("MANAGE_NICKNAMES")) permissions += "MANAGE_NICKNAMES, ";
- if(role.permissions.has("MANAGE_ROLES")) permissions += "MANAGE_ROLES, ";
- if(role.permissions.has("MANAGE_WEBHOOKS")) permissions += "MANAGE_WEBHOOKS, ";
- if(role.permissions.has("MANAGE_EMOJIS")) permissions += "MANAGE_EMOJIS, ";
- permissions = permissions.slice(0, -2);
- permissions += "```";
-
- var embed = new Discord.MessageEmbed();
- embed.setColor(role.color);
- embed.setTitle(role.name);
- embed.setDescription(
- `• **ID:** ${role.id}\n• **Hex:** ${role.hexColor}\n• **Members:** ${role.members.size}\n• **Position:** ${role.position}\n• **Hoisted:** ${role.hoist}`
- );
- embed.addField(`**Permissions:**`, permissions)
- message.channel.send(embed)
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: ["rinfo"],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "roleinfo",
- category: "Utility",
- description: "Gives information about a role.",
- usage: "roleinfo [role]"
-};
\ No newline at end of file
diff --git a/src/commands/sans.js b/src/commands/sans.js
deleted file mode 100644
index ae5b3af..0000000
--- a/src/commands/sans.js
+++ /dev/null
@@ -1,36 +0,0 @@
-const url = "https://demirramon.com/gen/undertale_text_box.png";
-exports.run = (client, message, args) => {
- let text = args.join(" ");
- if (!text) {
- return message.channel.send(
- `<:error:466995152976871434> No message provided. Usage: \`${client.commands.get(`sans`).help.usage}\``
- );
- }
-
- message.channel.startTyping();
-
- let params = "box=undertale&boxcolor=white&character=undertale-sans&expression=default&charcolor=white&font=determination&asterisk=true&mode=regular&text=" + encodeURIComponent(text);
-
- try {
- message.channel.stopTyping();
- message.channel.send({files: [new Discord.MessageAttachment(url + "?" + params, "undertale.png")]});
- } catch(err) {
- message.channel.stopTyping();
- message.channel.send(`<:error:466995152976871434> Error when generating image: \`${err}\``)
- }
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["undertale"],
- permLevel: "User",
- requiredPerms: ["ATTACH_FILES"]
-};
-
-exports.help = {
- name: "sans",
- category: "Fun",
- description: "Generates a sans text box",
- usage: "sans [message]"
-};
\ No newline at end of file
diff --git a/src/commands/say.js b/src/commands/say.js
deleted file mode 100644
index e196847..0000000
--- a/src/commands/say.js
+++ /dev/null
@@ -1,28 +0,0 @@
-exports.run = (client, message, args, level) => {
- if(!args[0]) {
- return message.channel.send(
- `<:error:466995152976871434> No message provided. Usage: \`${client.commands.get(`echo`).help.usage}\``
- );
- };
- if (message.content.includes("@everyone")) {
- return message.channel.send(`<@${message.author.id}>`);
- };
-
- message.delete().catch(O_o => {});
- message.channel.send(args.join(" "));
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["echo"],
- permLevel: "User",
- requiredPerms: ["MANAGE_MESSAGES"]
-};
-
-exports.help = {
- name: "say",
- category: "Fun",
- description: "Makes Woomy copy what the user says.",
- usage: "echo <-hide> [message]"
-};
diff --git a/src/commands/servericon.js b/src/commands/servericon.js
deleted file mode 100644
index 2eb44c4..0000000
--- a/src/commands/servericon.js
+++ /dev/null
@@ -1,18 +0,0 @@
-exports.run = (client, message) => {
- message.channel.send(`**${message.guild}'s** icon is:\n${message.guild.iconURL({format: "png", dynamic: true, size: 2048})}`)
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: ["sicon", "guildicon"],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "servericon",
- category: "Utility",
- description: "Displays the icon for the server.",
- usage: "servericon"
-};
diff --git a/src/commands/serverinfo.js b/src/commands/serverinfo.js
deleted file mode 100644
index 89c2230..0000000
--- a/src/commands/serverinfo.js
+++ /dev/null
@@ -1,99 +0,0 @@
-exports.run = (client, message) => {
-
- var guild = message.guild
- var badges = "";
- var members = `${guild.memberCount} (${guild.memberCount-guild.members.cache.filter(member => member.user.bot).size} users | ${guild.members.cache.filter(member => member.user.bot).size} bots)`;
-
- var roles = 0;
- guild.roles.cache.forEach((role) => {
- roles = roles + 1;
- });
-
- var channels = 0;
- var categories = 0;
- var text = 0;
- var voice = 0;
-
- guild.channels.cache.forEach((channel) => {
- if(channel.type == "category") {
- categories = categories + 1;
- } else {
- if(channel.type == "text") {
- text = text + 1;
- };
-
- if(channel.type == "voice") {
- voice = voice + 1;
- };
-
- channels = channels + 1;
- };
- });
-
- var channelString = `${channels} (${text} text | ${voice} voice | ${categories} categories)`
-
- if(guild.premiumTier > 0) {
- badges = badges += "<:boosted:685704824175853624> "
- }
-
- if(guild.partnered == true) {
- badges = badges += "<:partnered:685704834779054107> "
- }
-
- if(guild.verified == true) {
- badges = badges += "<:verified:685704812435734569>"
- }
-
- if(badges.length > 0) {
- badges = badges += "\n"
- }
-
- var boosts;
- if(guild.premiumTier == 1) {
- boosts = `${guild.premiumSubscriptionCount} (level 1)`
- } else if(guild.premiumTier == 2) {
- boosts = `${guild.premiumSubscriptionCount} (level 2)`
- } else if(guild.premiumTier == 3) {
- boosts = `${guild.premiumSubscriptionCount} (level 3)`
- } else {
- boosts = guild.premiumSubscriptionCount;
- };
-
- var emojis = 0;
- var static = 0;
- var animated = 0;
-
- guild.emojis.cache.forEach((emoji) => {
- if(emoji.animated == true) {
- animated = animated + 1;
- } else {
- static = static + 1;
- };
- emojis = emojis + 1;
- });
-
- emojiString = `${emojis} (${static} static | ${animated} animated)`
-
- let embed = new Discord.MessageEmbed()
- .setColor(message.guild.member(client.user).displayHexColor)
- .setTitle(guild.name)
- .setDescription(`${badges}• **ID:** ${guild.id}\n• **Owner:** ${guild.owner}\n• **Region:** ${guild.region.toProperCase()}\n• **Boosts:** ${boosts}\n• **Members:** ${members}\n• **Channels:** ${channelString}\n• **Roles:** ${roles}\n• **Emojis:** ${emojiString}\n• **Creation date:** ${guild.createdAt}`)
- .setThumbnail(message.guild.iconURL({format: "png", dynamic: true, size: 2048}));
-
- message.channel.send(embed);
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: ["sinfo", "guildinfo", "ginfo", "server"],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "serverinfo",
- category: "Utility",
- description: "Displays some useful information about the current server.",
- usage: "serverinfo"
-};
diff --git a/src/commands/settings.js b/src/commands/settings.js
deleted file mode 100644
index eb1f66c..0000000
--- a/src/commands/settings.js
+++ /dev/null
@@ -1,101 +0,0 @@
-exports.run = async (client, message, args) => {
-
- const settings = message.settings;
- if (!client.settings.has(message.guild.id)) client.settings.set(message.guild.id, {});
-
- modChan = message.guild.channels.cache.find(channel => channel.name === settings.modlogsChannel) || "__Disabled__";
- chatChan = message.guild.channels.cache.find(channel => channel.name === settings.chatlogsChannel) || "__Disabled__"
- greetChan = message.guild.channels.cache.get(settings.welcomeChannel) || "__Disabled__";
- prefix = settings.prefix;
-
- var raidMode;
- var rmDisabled = false;
- if(settings.raidMode == "off") {
- raidMode = "__Disabled__"
- rmDisabled = true;
- } else {
- raidMode = `\`${settings.raidMode}`
- }
-
- if(settings.raidModeStrict == "on") {
- raidMode += " (strict)`"
- } else if(rmDisabled != true) {
- raidMode += "`"
- }
-
- var modRole = message.guild.roles.cache.get(settings.modRole);
- var adminRole = message.guild.roles.cache.get(settings.adminRole);
- var autorole = message.guild.roles.cache.get(settings.autorole);
- var mutedRole = message.guild.roles.cache.get(settings.mutedRole);
- var blacklist = "";
-
- if(settings.modRole == "off" || !modRole) {
- modRole = "__None set__";
- } else {
- modRole = "`" + modRole.name + "`";
- }
-
- if(settings.adminRole == "off" || !adminRole) {
- adminRole = "__None set__";
- } else {
- adminRole = "`" + adminRole.name + "`";
- }
-
- if(settings.autorole == "off" || !autorole) {
- autorole = "__None set__";
- } else {
- autorole = "`" + autorole.name + "`";
- }
-
- if(settings.mutedRole == "off" || !mutedRole) {
- mutedRole = "__None set__";
- } else {
- mutedRole = "`" + mutedRole.name + "`";
- }
-
- if(settings.welcomeMessage == "off") {
- welcomeMessage = "__Disabled__";
- } else {
- welcomeMessage = "`" + settings.welcomeMessage + "`";
- }
-
- if(settings.leaveMessage == "off") {
- leaveMessage = "__Disabled__";
- } else {
- leaveMessage = "`" + settings.leaveMessage + "`";
- }
-
- if(settings.blacklisted == "ARRAY" || settings.blacklisted.length < 1) {
- blacklist = "__Disabled__";
- } else {
- if(settings.blacklisted.length > 0) {
- settings.blacklisted.forEach(function(user) {
- blacklist += "`" + (client.users.cache.get(user).tag || user.tag) + "`, "
- });
- blacklist = blacklist.substring(0, blacklist.length - 2);
- };
- };
-
- embed = new Discord.MessageEmbed()
- embed.setAuthor("Settings for: " + message.guild.name, message.guild.iconURL({dynamic: true}))
- embed.setColor(message.guild.member(client.user).displayHexColor)
- embed.setDescription("You can edit these settings using the commands in the 'configure' section of the help command.")
- embed.addFields({ name: "General:", value: `Prefix: \`${prefix}\`\nChat logging: ${chatChan}\nMod logging: ${modChan}\nRaid mode: ${raidMode}\nJoin/leave channel: ${greetChan}\nWelcome message: ${welcomeMessage}\nLeave message: ${leaveMessage}`, inline: true}, {name: "Roles:", value: `Moderator: ${modRole}\nAdministrator: ${adminRole}\nMuted: ${mutedRole}\nBlacklisted: ${blacklist}\nAutorole: ${autorole}`, inline: true})
- message.channel.send(embed)
-
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: ["config"],
- permLevel: "Administrator",
- requiredPerms: []
-};
-
-exports.help = {
- name: "settings",
- category: "Configure",
- description: "View your server's settings.",
- usage: "settings"
-};
diff --git a/src/commands/sexuality.js b/src/commands/sexuality.js
deleted file mode 100644
index c41930b..0000000
--- a/src/commands/sexuality.js
+++ /dev/null
@@ -1,36 +0,0 @@
-const sexualities = require ("../../resources/other/sexualities.json");
-exports.run = async (client, message, args) => {
- var output = "";
- if(!args[0]) {
- for (var key of Object.keys(sexualities)) {
- output += `${key}, `
- };
- return message.channel.send(`__**Sexualities:**__\n${output.slice(0, -2)}`);
- } else {
- if(args.join(" ").toLowerCase() == "attack helicopter" || args.join(" ").toLowerCase() == "apache attack helicopter" || args.join(" ").toLowerCase() == "apache") {
- return message.channel.send({
- files: [new Discord.MessageAttachment("./resources/images/attackhelicopter.jpg")]
- });
- }
- output = sexualities[args.join(" ").toLowerCase()];
- if(!output) {
- return message.channel.send("<:error:466995152976871434> No results for that query.");
- };
- return message.channel.send(`__**${output.name.toProperCase()}:**__\n${output.description}`);
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["sexualities"],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "sexuality",
- category: "Fun",
- description: "Gives you information about the specified sexuality.",
- usage: "sexuality [sexuality]"
-};
diff --git a/src/commands/ship.js b/src/commands/ship.js
deleted file mode 100644
index 3850d87..0000000
--- a/src/commands/ship.js
+++ /dev/null
@@ -1,53 +0,0 @@
-exports.run = async (client, message, args) => {
-
- var name, name1;
- var rating = Math.floor(Math.random() * 100) + 1;
- var hearts = [
- "❤️",
- "🧡",
- "💛",
- "💚",
- "💙",
- "💜"
- ];
-
- if(args.length < 2) {
- return message.channel.send(`<:error:466995152976871434> Please include two names/users.`)
- }
-
- if(message.guild && message.mentions.members && message.mentions.members.size > 0) {
- name = message.mentions.members.first().displayName;
- };
-
- if(message.guild && message.mentions.members && message.mentions.members.size > 1) {
- name1 = message.mentions.members.last().displayName;
- };
-
- if(!name) {
- name = args[0];
- };
-
- if(!name1) {
- name1 = args[1];
- };
-
- shipName = name.substr(0, client.intBetween(1,name.length))+name1.substr(client.intBetween(0,name1.length));
-
- message.channel.send(`__**Ship Generator:**__\n${hearts.random()} Ship Name: \`${shipName}\`\n${hearts.random()} Compatibility rating: \`${rating}%\``)
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "ship",
- category: "Fun",
- description: "Ship two people together <3",
- usage: "ship [name/user] [name/user]"
-};
-
diff --git a/src/commands/skip.js b/src/commands/skip.js
deleted file mode 100644
index c997c18..0000000
--- a/src/commands/skip.js
+++ /dev/null
@@ -1,66 +0,0 @@
-const Discord = require("discord.js")
-exports.run = (client, message, args, level) => {
- let guild = client.music.getGuild(message.guild.id);
-
- if(guild.queue.length < 1 || !guild.playing || !guild.dispatcher) return message.channel.send(
- "<:error:466995152976871434> Nothing is playing."
- );
-
- let vc = message.guild.members.cache.get(client.user.id).voiceChannel;
-
- if(vc != message.member.voiceChannel) return message.channel.send(
- '<:error:466995152976871434> You need to be in my voice channel to use this command!'
- );
-
- if(guild.queue[0].requestedBy.id == message.author.id) {
- skip_song(guild);
-
- message.channel.send(
- `<:skip:467216735356059660> Song has been skipped by the user who requested it.`
- );
-
- return;
- }
-
- if (guild.skippers.indexOf(message.author.id) == -1) {
- guild.skippers.push(message.author.id);
-
- if (guild.skippers.length >= Math.ceil(vc.members.filter(member => !member.user.bot).size / 2)) {
-
- skip_song(guild);
-
- message.channel.send(
- `<:skip:467216735356059660> Song has been skipped.`
- );
-
- } else {
- message.channel.send(
- `<:success:466995111885144095> Your vote has been acknowledged! **${guild.skippers.length + "/" + Math.ceil(vc.members.filter(member => !member.user.bot).size / 2)}**`
- );
- };
-
- } else {
- message.channel.send(
- "<:denied:466995195150336020> You cannot vote twice!"
- );
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: ["voteskip"],
- permLevel: "User",
- requiredPerms: ["SPEAK"]
-};
-
-exports.help = {
- name: "skip",
- category: "Music",
- description: "Vote to skip the currently playing song. Song will be skipped instantly if executed by the user who requested it.",
- usage: "skip"
-};
-
-function skip_song(guild) {
- guild.dispatcher.end("silent");
- }
\ No newline at end of file
diff --git a/src/commands/slap.js b/src/commands/slap.js
deleted file mode 100644
index c87c783..0000000
--- a/src/commands/slap.js
+++ /dev/null
@@ -1,69 +0,0 @@
-const API = require('nekos.life');
-const {sfw} = new API();
-exports.run = async (client, message, args) => {
- if(!args[0]) {
- return message.channel.send(`<:error:466995152976871434> You didn't say who you wanted to slap! Usage: \`${client.commands.get(`slap`).help.usage}\``)
- };
-
- var people = "";
-
- for (var i = 0; i < args.length; i++) {
- var user = client.getUserFromMention(args[i])
- if (user) {
- user = message.guild.members.cache.get(user.id).displayName;
- } else {
- users = client.searchForMembers(message.guild, args[i]);
- if (users.length > 1)
- return message.channel.send(
- "<:error:466995152976871434> Found multiple users for `" + args[i] + "`, Please be more specific or mention the user instead."
- );
- else if (users.length == 0)
- return message.channel.send(
- "<:error:466995152976871434> That user doesn't seem to exist. Try again!"
- );
- user = users[0].displayName;
- };
- if(i+1 == args.length && args.length > 1) {
- people += `**and** ${user}!`
- } else if(args.length < 2) {
- people += `${user}!`;
- } else if(args.length == 2 && i == 0) {
- people += `${user} `;
- } else {
- people += `${user}, `;
- };
- };
-
-
-
- message.channel.startTyping();
- try {
- sfw.slap().then((json) => {
- embed = new Discord.MessageEmbed();
- embed.setImage(json.url)
- embed.setColor(client.embedColour(message));
- embed.setDescription(`**${message.guild.members.cache.get(message.author.id).displayName}** slapped **${people}**`)
- message.channel.send(embed)
- message.channel.stopTyping();
- });
- } catch (err) {
- client.logger.error("slap.js: " + err);
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`)
- message.channel.stopTyping();
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "slap",
- category: "Action",
- description: "Slap someone >:3",
- usage: "slap [@user/user] (you can slap as many people as you want!)"
-};
diff --git a/src/commands/smug.js b/src/commands/smug.js
deleted file mode 100644
index 011f2bd..0000000
--- a/src/commands/smug.js
+++ /dev/null
@@ -1,33 +0,0 @@
-const API = require('nekos.life');
-const {sfw} = new API();
-exports.run = async (client, message) => {
- message.channel.startTyping();
- try {
- sfw.smug().then((json) => {
- embed = new Discord.MessageEmbed();
- embed.setImage(json.url)
- embed.setColor(client.embedColour(message));
- message.channel.send(embed)
- message.channel.stopTyping();
- });
- } catch (err) {
- client.logger.error("smug.js: " + err);
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`)
- message.channel.stopTyping();
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "smug",
- category: "Action",
- description: "Sends a smug gif.",
- usage: "smug"
-};
diff --git a/src/commands/softban.js b/src/commands/softban.js
deleted file mode 100644
index 1b602c5..0000000
--- a/src/commands/softban.js
+++ /dev/null
@@ -1,99 +0,0 @@
-exports.run = async (client, message, args) => {
- const settings = (message.settings = client.getSettings(message.guild.id));
-
- if(!args[0]) {
- return message.channel.send(
- `<:error:466995152976871434> No username provided. Usage: \`${client.commands.get(`ban`).help.usage}\``
- );
- };
-
- let user = message.mentions.members.first();
-
- if (!user) {
- let users;
- users = client.searchForMembers(message.guild, args[0]);
- if (users.length > 1)
- return message.channel.send(
- "<:error:466995152976871434> Found multiple users! Please be more specific or mention the user instead."
- );
- else if (users.length == 0)
- return message.channel.send(
- "<:error:466995152976871434> That user doesn't seem to exist. Try again!"
- );
- user = users[0];
- };
-
- if(!user.bannable) {
- return message.channel.send(`<:error:466995152976871434> Specified user is not bannable.`)
- };
-
- let mod = message.guild.member(message.author);
- let bot = message.guild.member(client.user);
-
- if (user.roles.highest.position >= mod.roles.highest.position) {
- return message.channel.send(
- `<:error:466995152976871434> You can't softban people who are higher ranked than you are!`
- );
- };
-
- if (user.roles.highest.position >= bot.roles.highest.position) {
- return message.channel.send(
- `<:error:466995152976871434> I can't softban people who are higher ranked than you myself!`
- );
- };
-
- if(!user.bannable) {
- return message.channel.send(`<:error:466995152976871434> Specified user is not bannable.`)
- };
-
- var days = args[args.length - 1]
- try {
- days = Number(days);
- } catch(err) {};
-
- console.log(typeof days)
- console.log(days)
-
- if(isNaN(days)) {
- return message.channel.send(`<:error:466995152976871434> Invalid number. Did you forget to specify how many days worth of messages to clear? Usage: \`${client.commands.get(`softban`).help.usage}\``)
- } else if (days < 1 || days > 7) {
- return message.channel.send(`<:error:466995152976871434> Number too large/small. The max amount of days I can clear is 7.`)
- } else {
- await message.guild.members.ban(user, {reason: `Softbanned by ${message.author.tag}`, days: days});
- await message.guild.members.unban(user);
- message.channel.send(`<:success:466995111885144095> Softbanned \`${user.user.tag}\``);
-
- if (settings.modlogsChannel !== "off") {
- const channel = message.guild.channels.cache.find(
- channel => channel.name === settings.modlogsChannel
- );
-
- if (channel) {
- let embed = new Discord.MessageEmbed();
- embed.setColor("#F38159");
- embed.setAuthor("User softbanned!", user.user.avatarURL({format: "png", dynamic: true, size: 2048}));
- embed.setDescription(
- `• User: ${user.user.tag} (${user.user.id})\n• Mod: ${message.author} (${message.author.id})\n• Days cleared: ${days}`
- );
- try {
- channel.send(embed);
- } catch (err) {};
- };
- };
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Moderator",
- requiredPerms: ["BAN_MEMBERS"]
-};
-
-exports.help = {
- name: "softban",
- category: "Moderation",
- description: "Bans then unbans a user, clearing their messages.",
- usage: "softban [user] [days]"
-};
diff --git a/src/commands/spoilerise.js b/src/commands/spoilerise.js
deleted file mode 100644
index 25ab221..0000000
--- a/src/commands/spoilerise.js
+++ /dev/null
@@ -1,28 +0,0 @@
-exports.run = async (client, message, args) => {
- if(!args[0]) {
- return message.channel.send(`<:error:466995152976871434> You didn't provide any text! Usage: \`${client.commands.get(`spoiler`).help.usage}\``)
- };
-
- var output = `||${[...message.cleanContent.substring(9)].join("||||")}||`;
-
- if(output.length > 2000) {
- output = output.slice(0, -Math.abs(output.length - 2000))
- };
-
- message.channel.send(output)
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["spoilerize", "spoiler"],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "spoilerise",
- category: "Fun",
- description: "Spoilers every letter in the provided text.",
- usage: "spoiler [text]"
-};
diff --git a/src/commands/stop.js b/src/commands/stop.js
deleted file mode 100644
index 695dd04..0000000
--- a/src/commands/stop.js
+++ /dev/null
@@ -1,32 +0,0 @@
-const Discord = require("discord.js");
-
-exports.run = async (client, message) => {
- let guild = client.music.getGuild(message.guild.id);
-
- if(guild.queue.length < 1 || !guild.playing || !guild.dispatcher) return message.channel.send("<:error:466995152976871434> Nothing is playing.");
- if(!message.member.voice.channel) return message.channel.send('<:error:466995152976871434> You need to be in voice channel to use this command!');
-
- guild.playing = false;
- guild.paused = false;
- guild.queue = [];
-
- guild.dispatcher.end("silent");
-
- message.channel.send("<:stop:467639381390262284> Playback stopped!");
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Moderator",
- requiredPerms: []
-};
-
-exports.help = {
- name: "stop",
- category: "Music",
- description: "Clears the queue and disconnects from the voice channel. (run this if music stopS working)",
- usage: "stop"
-};
-
diff --git a/src/commands/support.js b/src/commands/support.js
deleted file mode 100644
index c15de88..0000000
--- a/src/commands/support.js
+++ /dev/null
@@ -1,18 +0,0 @@
-exports.run = async (client, message, args) =>{
- message.channel.send("Use this link to join my support server: https://discord.gg/HCF8mdv")
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: []
- };
-
-exports.help = {
- name: "support",
- category: "Utility",
- description: "Sends a link to Woomy's support/development server.",
- usage: "support"
- };
diff --git a/src/commands/takerole.js b/src/commands/takerole.js
deleted file mode 100644
index 408d0e3..0000000
--- a/src/commands/takerole.js
+++ /dev/null
@@ -1,86 +0,0 @@
-exports.run = async (client, message, [member, ...role2add], query) => {
- if (!member) {
- return message.channel.send(
- `<:error:466995152976871434> No user specified. Usage: \`${client.commands.get(`takerole`).help.usage}\``
- );
- }
- let user = message.mentions.members.first();
- let users;
- if (!user) {
- users = client.searchForMembers(message.guild, member);
- if (users.length > 1)
- return message.channel.send(
- "<:error:466995152976871434> Found multiple users, please be more specific or mention the user instead."
- );
- else if (users.length == 0)
- return message.channel.send(
- "<:error:466995152976871434> That user doesn't seem to exist. Try again!"
- );
- user = users[0];
- }
- let role = role2add.join(" ");
-
- gRole = client.findRole(role, message);
-
- if (!gRole) {
- return message.channel.send(`<:error:466995152976871434> That role doesn't seem to exist. Try again!`);
- };
-
- let moderator = message.guild.member(message.author)
- if (gRole.position >= moderator.roles.highest.position) {
- return message.channel.send(
- "<:error:466995152976871434> You cannot take roles higher than your own!"
- );
- }
-
- var bot = message.guild.members.cache.get(client.user.id)
- if (gRole.position >= bot.roles.highest.position) {
- return message.channel.send(
- `<:error:466995152976871434> I can't take roles higher than my own!`
- );
- }
- if (!user.roles.cache.has(gRole.id)) {
- return message.channel.send(
- "<:error:466995152976871434> They don't have that role!"
- );
- }
- await user.roles.remove(gRole.id);
- message.channel.send(
- `<:success:466995111885144095> Took the \`${gRole.name}\` role from \`${
- user.user.tag
- }\``
- );
-
- if (client.getSettings(message.guild.id).modlogsChannel !== "off") {
- const channel = message.guild.channels.cache.find(
- channel => channel.name === client.getSettings(message.guild.id).modlogsChannel
- );
-
- if (channel) {
- let embed = new Discord.MessageEmbed();
- embed.setColor("#008369");
- embed.setAuthor("Role taken:", user.user.avatarURL({format: "png", dynamic: true, size: 2048}));
- embed.setDescription(`• User: ${user} (${user.user.id})\n• Mod: ${message.author} (${message.author.id})\n• Role: ${gRole}`)
- try {
- channel.send({ embed });
- } catch (err) {
- // probably no permissions to send messages/embeds there
- };
- };
- };
-};
-
- exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: ["removerole"],
- permLevel: "Moderator",
- requiredPerms: ["MANAGE_ROLES"]
- };
-
- exports.help = {
- name: "takerole",
- category: "Moderation",
- description: "Takes a role from the specified user.",
- usage: "takerole [user] [role]"
- };
\ No newline at end of file
diff --git a/src/commands/tickle.js b/src/commands/tickle.js
deleted file mode 100644
index e75a771..0000000
--- a/src/commands/tickle.js
+++ /dev/null
@@ -1,69 +0,0 @@
-const API = require('nekos.life');
-const {sfw} = new API();
-exports.run = async (client, message, args) => {
- if(!args[0]) {
- return message.channel.send(`<:error:466995152976871434> You didn't say who you wanted to tickle! Usage: \`${client.commands.get(`tickle`).help.usage}\``)
- };
-
- var people = "";
-
- for (var i = 0; i < args.length; i++) {
- var user = client.getUserFromMention(args[i])
- if (user) {
- user = message.guild.members.cache.get(user.id).displayName;
- } else {
- users = client.searchForMembers(message.guild, args[i]);
- if (users.length > 1)
- return message.channel.send(
- "<:error:466995152976871434> Found multiple users for `" + args[i] + "`, Please be more specific or mention the user instead."
- );
- else if (users.length == 0)
- return message.channel.send(
- "<:error:466995152976871434> That user doesn't seem to exist. Try again!"
- );
- user = users[0].displayName;
- };
- if(i+1 == args.length && args.length > 1) {
- people += `**and** ${user}!`
- } else if(args.length < 2) {
- people += `${user}!`;
- } else if(args.length == 2 && i == 0) {
- people += `${user} `;
- } else {
- people += `${user}, `;
- };
- };
-
-
-
- message.channel.startTyping();
- try {
- sfw.tickle().then((json) => {
- embed = new Discord.MessageEmbed();
- embed.setImage(json.url)
- embed.setColor(client.embedColour(message));
- embed.setDescription(`**${message.guild.members.cache.get(message.author.id).displayName}** tickled **${people}**`)
- message.channel.send(embed)
- message.channel.stopTyping();
- });
- } catch (err) {
- client.logger.error("tickle.js: " + err);
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`)
- message.channel.stopTyping();
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "tickle",
- category: "Action",
- description: "Tickle someone!",
- usage: "tickle [@user/user] (you can tickle as many people as you want!)"
-};
diff --git a/src/commands/unmute.js b/src/commands/unmute.js
deleted file mode 100644
index abf38f1..0000000
--- a/src/commands/unmute.js
+++ /dev/null
@@ -1,90 +0,0 @@
-exports.run = async (client, message, args, level) => {
- const settings = message.settings;
-
- if(!args[0]) {
- return message.channel.send("<:error:466995152976871434> Who am I meant to unmute?")
- }
- let user = message.mentions.members.first();
- let users;
- if (!user) {
- users = client.searchForMembers(message.guild, args[0]);
- if (users.length > 1)
- return message.channel.send(
- "<:error:466995152976871434> Found multiple users! Please be more specific or mention the user instead."
- );
- else if (users.length == 0)
- return message.channel.send(
- "<:error:466995152976871434> That user doesn't seem to exist. Try again!"
- );
- user = users[0];
- }
- if (user.user.id === client.user.id) {
- return message.channel.send("lol no")
- }
-
- let moderator = message.guild.member(message.author)
- if (message.settings.mutedRole.position >= moderator.roles.highest.position && level < 2) {
- return message.channel.send(
- "<:error:466995152976871434> The muted role is positioned above the moderator role! Please move the muted role below the moderator role."
- );
- }
- if (user.roles.highest.position >= moderator.roles.highest.position && moderator.user.id !== message.guild.ownerID) {
- return message.channel.send(
- `<:error:466995152976871434> You can't unmute people who have a higher role than you!`
- );
- };
- let bot = message.guild.member(client.user)
- if (user.roles.highest.position >= bot.roles.highest.position) {
- return message.channel.send(
- `<:error:466995152976871434> I can't unmute people who have a higher role than me!`
- );
- }
-
- let role = message.guild.roles.cache.get(settings.mutedRole)
- if(!role) {
- return message.channel.send(
- "<:error:466995152976871434> Mute role not found! Please set one using `~settings edit mutedRole `"
- );
- }
-
- if (!user.roles.cache.has(role.id)) {
- return message.channel.send("<:error:466995152976871434> They aren't muted!")
- }
-
- await user.roles.remove(role.id);
- message.channel.send(`<:success:466995111885144095> Unmuted \`${user.user.tag}\``)
-
-
- if (settings.modlogsChannel !== "off") {
- const channel = message.guild.channels.cache.find(
- channel => channel.name === settings.modlogsChannel
- );
-
- if (channel) {
- let embed = new Discord.MessageEmbed();
- embed.setColor("#7a2f8f");
- embed.setAuthor("User unmuted!", user.user.avatarURL({format: "png", dynamic: true, size: 2048}));
- embed.setDescription(`• User: ${user} (${user.user.id})\n• Mod: ${message.author} (${message.author.id})`)
- try {
- channel.send({ embed });
- } catch (err) {
- // probably no permissions to send messages/embeds there
- }
- }
- }
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Moderator",
- requiredPerms: ["MANAGE_ROLES", "MANAGE_CHANNELS"]
-};
-
-exports.help = {
- name: "unmute",
- category: "Moderation",
- description: "Allows a muted user to type again.",
- usage: "unmute [user]"
-};
diff --git a/src/commands/urban.js b/src/commands/urban.js
deleted file mode 100644
index b42f366..0000000
--- a/src/commands/urban.js
+++ /dev/null
@@ -1,48 +0,0 @@
-Discord = require("discord.js");
-urban = require("relevant-urban");
-exports.run = async (client, message, args) => {
- if (message.channel.nsfw === false) return message.channel.send(
- "<:error:466995152976871434> This command can only be executed in channels marked as NSFW!"
- );
- if (args < 1) return message.channel.send(
- `<:error:466995152976871434> You did not tell me what to search for! Usage: \`${client.commands.get(`urban`).help.usage}\`
- `);
- let phrase = args.join(" ");
- let output = await urban(args.join(' ')).catch(e => {
- return message.channel.send("<:error:466995152976871434> No results found for `" + phrase + "`")
- });
-
- if(output.definition.length > 2000) return message.channel.send(
- `<:error:466995152976871434> Definition cannot exceed 2000 characters! Use this link instead: ${output.urbanURL}`
- );
- if(output.example.length > 2000) return message.channel.send(
- "<:error:466995152976871434> Example cannot exceed 2000 characters!"
- );
-
- embed = new Discord.MessageEmbed()
- .setTitle(output.word)
- .setURL(output.urbanURL)
- .setColor("#EFFF00")
- .setDescription(output.definition || "None")
- .addFields(
- {name: "Example", value: output.example || "None"}, {name: "Upvotes", value: output.thumbsUp, inline: true}, {name: "Downvotes", value: output.thumbsDown, inline: true}
- )
- .setFooter(`Submitted by ${output.author}`)
- message.channel.send(embed);
-
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: []
-};
-
-exports.help = {
- name: "urban",
- category: "Fun",
- description: "Grabs a definition from the urban dictonary.",
- usage: "urban [word]"
-};
diff --git a/src/commands/userinfo.js b/src/commands/userinfo.js
deleted file mode 100644
index 98d6738..0000000
--- a/src/commands/userinfo.js
+++ /dev/null
@@ -1,129 +0,0 @@
-const Discord = require("discord.js");
-const coolPeople = require('../../resources/other/coolpeople.json')
-exports.run = (client, message, args) => {
- var user, guild, status, createdAt, avurl, tag, id;
- var nick = "", roles = "", presence = "", badges = "";
- var coolPerson = false;
- var friendos = coolPeople.coolPeople;
-
- if(message.guild) {
- user = message.mentions.members.first();
-
- if(!args[0]) {
- user = message.guild.members.cache.get(message.author.id)
- };
-
- if (!user) {
- var users;
- users = client.searchForMembers(message.guild, args[0]);
- if (users.length > 1)
- return message.channel.send(
- "<:error:466995152976871434> Found multiple users! Please be more specific or mention the user instead."
- );
- else if (users.length == 0)
- return message.channel.send(
- "<:error:466995152976871434> That user doesn't seem to exist. Try again!"
- );
- user = users[0];
- };
-
- if(user.nickname) {
- nick = `\n• **Nickname:** ${user.nickname}`;
- };
-
- for (var i = 0; i < friendos.length; i++) {
- if (user.user.id == friendos[i])
- coolPerson = true;
- };
-
- if(coolPerson == true) {
- badges += "🌟"
- }
-
- if(user.user.id == message.guild.ownerID) {
- badges += "<:owner:685703193694306331>"
- }
-
- if(user.user.bot) {
- badges += "<:bot:686489601678114859>"
- }
-
-
- if(badges.length > 0) {
- badges += "\n"
- }
-
- user.roles.cache.forEach((role) => {
- roles = roles + role.name + "`, `"
- });
-
- roles = roles.substr(0, roles.length -4);
-
- guild = `\n• **Roles:** \`${roles}\`\n• **Server join date:** ${user.joinedAt}`;
-
- id = user.user.id;
- tag = user.user.tag;
- colour = user.displayHexColor;
- avurl = user.user.avatarURL({format: "png", dynamic: true, size: 2048});
- createdAt = user.user.createdAt;
- } else {
- id = user.id;
- tag = user.tag;
- colour = ["#ff9d68", "#ff97cb", "#d789ff", "#74FFFF"].random();
- avurl = user.avatarURL({format: "png", dynamic: true, size: 2048});
- createdAt = user.createdAt;
- };
-
- if(user.presence.status == "online") {
- status = `online <:status_online:685462758023626762>`
- };
-
- if(user.presence.status == "idle") {
- status = `idle <:status_idle:685462771529154561>`
- };
-
- if(user.presence.status == "dnd") {
- status = `do not disturb <:status_dnd:685462782963220495>`
- };
-
- if(user.presence.status == "offline") {
- status = `offline <:status_offline:685462758229016633>`
- };
-
- if(user.presence.activities[0]) {
- presence = "\n• **Presence:** ";
- if(user.presence.activities[0].type == "PLAYING") {
- presence += `Playing ${user.presence.activities[0].name}`;
- };
-
- if(user.presence.activities[0].type == "STREAMING") {
- presence += `Streaming ${user.presence.activities[0].name}`;
- };
-
- if(user.presence.activities[0].type == "CUSTOM_STATUS") {
- presence += `${user.presence.activities[0].state}`;
- };
- };
-
- embed = new Discord.MessageEmbed();
- embed.setTitle(tag);
- embed.setThumbnail(avurl);
- embed.setDescription(`${badges}• **ID:** ${id}${nick}\n• **Status:** ${status}${presence}${guild}\n• **Account created:** ${createdAt}`)
- embed.setColor(colour);
- message.channel.send(embed);
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: ["uinfo", "user"],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "userinfo",
- category: "Utility",
- description: "Displays some useful information about the specified user.",
- usage: "userinfo "
-};
diff --git a/src/commands/weather.js b/src/commands/weather.js
deleted file mode 100644
index ef01bc8..0000000
--- a/src/commands/weather.js
+++ /dev/null
@@ -1,64 +0,0 @@
-const weather = require("weather-js");
-exports.run = async (client, message, args, error) => {
- if(!args[0]) {
- return message.channel.send(
- `<:error:466995152976871434> You didn't give me a location. Usage: \`${client.commands.get(`weather`).help.usage}\``
- );
- };
-
- message.channel.startTyping();
-
- try {
- weather.find({search: args.join(" "), degreeType: 'C'}, function(err, result) {
- if(err) return message.channel.send(`<:error:466995152976871434> API error: \`${error}\``)
- if(result.length < 2 || !result) {
- message.channel.stopTyping();
- return message.channel.send("<:error:466995152976871434> City not found!");
- };
-
- var location = result[0].location;
- var current = result[0].current;
-
- var warning = (`${location.alert}` || "No warnings");
-
- var embedColour;
- if (current.temperature < 0) {
- embedColour = "#addeff";
- }else if (current.temperature < 20) {
- embedColour = "#4fb8ff";
- }else if (current.temperature < 26) {
- embedColour = "#ffea4f";
- }else if (current.temperature < 31) {
- embedColour = "#ffa14f"
- } else {
- embedColour = "#ff614f"
- };
-
- embed = new Discord.MessageEmbed();
- embed.setAuthor(`Weather for ${location.name}:`)
- embed.setDescription(`• **Condition:** ${current.skytext}\n• **Temperature:** ${current.temperature}°C\n• **Feels like:** ${current.feelslike}°C\n• **Humidity:** ${current.humidity}%\n• **Wind:** ${current.winddisplay}\n• **Warnings:** ${warning}`)
- embed.setThumbnail(current.imageUrl)
- embed.setFooter(`Last updated at ${current.observationtime} ${current.date}`)
- embed.setColor(embedColour)
- message.channel.stopTyping();
- message.channel.send(embed)
- });
- } catch(err) {
- return message.channel.send(`<:error:466995152976871434> API error: \`${err}\``)
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: ["EMBED_LINKS"]
-};
-
-exports.help = {
- name: "weather",
- category: "Utility",
- description: "Tells you the weather",
- usage: "weather [location]"
-};
\ No newline at end of file
diff --git a/src/commands/welcome.js b/src/commands/welcome.js
deleted file mode 100644
index b183b59..0000000
--- a/src/commands/welcome.js
+++ /dev/null
@@ -1,45 +0,0 @@
-const Discord = require("discord.js")
-exports.run = async (client, message, args, level) => {
-
- const settings = message.settings;
- const defaults = client.config.defaultSettings;
- const overrides = client.settings.get(message.guild.id);
- if (!client.settings.has(message.guild.id)) client.settings.set(message.guild.id, {});
-
- if (args[0]) {
- const joinedValue = args.join(" ");
- if (joinedValue === settings.welcomeMessage) return message.channel.send(
- "<:error:466995152976871434> The welcome message is already set to that!"
- );
- if (!client.settings.has(message.guild.id)) client.settings.set(message.guild.id, {});
- if (joinedValue === "off") {
- if (!client.settings.has(message.guild.id)) client.settings.set(message.guild.id, {});
- client.settings.set(message.guild.id, "off", "welcomeMessage");
- return message.channel.send(`<:success:466995111885144095> Welcome messages have been disabled.`);
- }
- client.settings.set(message.guild.id, joinedValue, "welcomeMessage");
- client.settings.set(message.guild.id, message.channel.id, "welcomeChannel")
- message.channel.send(`<:success:466995111885144095> Set the welcome message to \`${joinedValue}\``);
- } else {
- if (settings.welcomeMessage === "off") {
- message.channel.send(`Welcome messages are off.`)
- } else {
- message.channel.send(`The current welcome message is: \`${settings.welcomeMessage}\``)
- }
- }
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: true,
- aliases: [],
- permLevel: "Administrator",
- requiredPerms: []
-};
-
-exports.help = {
- name: "welcome",
- category: "Configure",
- description: "Sets the welcome message for this server. try using [[server]], [[user]] and [[members]] in your message!",
- usage: "welcome [message] **OR** welcome off"
-};
diff --git a/src/commands/woomy.js b/src/commands/woomy.js
deleted file mode 100644
index a9e17c4..0000000
--- a/src/commands/woomy.js
+++ /dev/null
@@ -1,33 +0,0 @@
-const Discord = require("discord.js")
-exports.run = async (client, message) =>{
- message.channel.send("Woomy!")
-
- const voiceChannel = message.member.voice.channel;
-
- if (!voiceChannel) return;
- if (!voiceChannel.permissionsFor(message.client.user).has('CONNECT')) return;
- if (!voiceChannel.permissionsFor(message.client.user).has('SPEAK')) return;
-
- if (client.music.getGuild(message.guild.id).playing == true || !client.music.getGuild(message.guild.id).queue[0]) return;
-
- voiceChannel.join()
- .then(connection => {
- const dispatcher = connection.play(`/home/container/resources/audio/WOOMY.MP3`);
- dispatcher.on("finish", end => {voiceChannel.leave()});
- })
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: []
- };
-
- exports.help = {
- name: "woomy",
- category: "Fun",
- description: "Woomy!",
- usage: "woomy"
- };
diff --git a/src/commands/yoda.js b/src/commands/yoda.js
deleted file mode 100644
index 496b929..0000000
--- a/src/commands/yoda.js
+++ /dev/null
@@ -1,33 +0,0 @@
-
-const fetch = require("node-fetch")
-exports.run = async (client, message, args) => {
- const speech = args.join(' ');
- if (!speech) {
- return message.channel.send(`<:error:466995152976871434> Please include text for me to convert to yodish. Yes.`)
- };
- message.channel.startTyping();
- try{
- fetch(`http://yoda-api.appspot.com/api/v1/yodish?text=${encodeURIComponent(speech.toLowerCase())}`)
- .then(res => res.json())
- .then(json => message.channel.send(json.yodish));
- message.channel.stopTyping();
- } catch(err) {
- message.channel.send(`<:error:466995152976871434> An error has occurred: ${err}`);
- message.channel.stopTyping();
- };
-};
-
-exports.conf = {
- enabled: true,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: []
-};
-
- exports.help = {
- name: "yoda",
- category: "Fun",
- description: "Turns any text you input into yodish. Yes.",
- usage: "yoda "
-};
\ No newline at end of file
diff --git a/src/commands/zalgo.js b/src/commands/zalgo.js
deleted file mode 100644
index e34d404..0000000
--- a/src/commands/zalgo.js
+++ /dev/null
@@ -1,30 +0,0 @@
-const zalgo = require("to-zalgo")
-exports.run = async (client, message, args) => {
- if(!args[0]) {
- return message.channel.send(`<:error:466995152976871434> You didn't provide any text! Usage: \`${client.commands.get(`zalgo`).help.usage}\``)
- };
-
- var output = zalgo(args.join(" "))
-
- if(output.length > 2000) {
- output = output.slice(0, -Math.abs(output.length - 2000))
- };
-
- message.channel.send(output)
- };
-
- exports.conf = {
- enabled: false,
- guildOnly: false,
- aliases: [],
- permLevel: "User",
- requiredPerms: []
- };
-
- exports.help = {
- name: "zalgo",
- category: "Fun",
- description: "Spoilers every letter in the provided text.",
- usage: "zalgo [text]"
- };
-
\ No newline at end of file
diff --git a/src/events/error.js b/src/events/error.js
deleted file mode 100644
index 23ce03a..0000000
--- a/src/events/error.js
+++ /dev/null
@@ -1,3 +0,0 @@
-module.exports = async (client, error) => {
- client.logger.log(`d.js err: \n${JSON.stringify(error.stack)}`, "error");
-};
diff --git a/src/events/guildCreate.js b/src/events/guildCreate.js
deleted file mode 100644
index 5f0f47f..0000000
--- a/src/events/guildCreate.js
+++ /dev/null
@@ -1,15 +0,0 @@
-const Discord = require("discord.js");
-module.exports = (client, guild) => {
- client.logger.log(`Guild joined.`, "info");
-
- client.settings.ensure(guild.id, client.config.defaultSettings);
-
- if(client.devmode == false) {
- channel = client.channels.cache.get("458896120639127552");
- embed = new Discord.MessageEmbed();
- embed.setColor("#F38159");
- embed.setDescription(`Joined a new server with \`${guild.members.cache.size}\` members! I'm now in \`${client.guilds.cache.size}\` servers.`)
- channel.send(embed)
- };
-};
-
diff --git a/src/events/guildDelete.js b/src/events/guildDelete.js
deleted file mode 100644
index a4c582d..0000000
--- a/src/events/guildDelete.js
+++ /dev/null
@@ -1,20 +0,0 @@
-const Discord = require('discord.js');
-module.exports = (client, guild) => {
- client.logger.log(`Guild left.`, "info");
-
- if(client.devmode === true) return;
-
- if(!guild.available) {
- return;
- };
-
- channel = client.channels.cache.get("458896120639127552");
- embed = new Discord.MessageEmbed();
- embed.setColor("#9494FF");
- embed.setDescription(`Left a server. I'm now in \`${client.guilds.cache.size}\` servers.`)
- channel.send(embed)
-
- if (client.settings.has(guild.id)) {
- client.settings.delete(guild.id);
- };
-};
diff --git a/src/events/guildMemberAdd.js b/src/events/guildMemberAdd.js
deleted file mode 100644
index 8e0ac6b..0000000
--- a/src/events/guildMemberAdd.js
+++ /dev/null
@@ -1,94 +0,0 @@
-module.exports = async (client, member) => {
- const settings = client.getSettings(member.guild.id);
-
- if (settings.welcomeMessage !== "off") {
- let chanExists = member.guild.channels.cache.get(settings.welcomeChannel)
- if (!chanExists) {
- return;
- };
- welcomeMessage = settings.welcomeMessage.replace("[[user]]", member.user);
- welcomeMessage = welcomeMessage.replace("[[server]]", member.guild.name);
- welcomeMessage = welcomeMessage.replace("[[members]]", member.guild.memberCount);
-
- member.guild.channels
- .cache.get(settings.welcomeChannel)
- .send(welcomeMessage)
- .catch(console.error);
- }
-
- if (settings.autorole !== "off") {
- let aRole = member.guild.roles.cache.get(settings.autorole)
- if (!aRole) {
- return;
- };
- await member.roles.add(aRole.id).catch(console.error);
- };
-
- if(settings.raidMode !== "off") {
- if(settings.raidModeStrict == "on") {
- member.kick("User bounced.")
-
- if (settings.chatlogsChannel !== "off") {
- const channel = member.guild.channels.cache.find(
- channel => channel.name === settings.chatlogsChannel
- );
-
- if (channel) {
- let embed = new Discord.MessageEmbed();
- embed.setColor("#1f1f1f");
- embed.setAuthor("User bounced:", member.user.avatarURL({dynamic: true}));
- embed.setDescription(`❯ User: ${member} (${member.user.id})`, true);
- embed.setFooter(`New users are being automatically kicked because raidmode is enabled.`)
- try {
- channel.send(embed);
- } catch (err) {
- // probably no permissions to send messages/embeds there
- };
- };
- return;
- }
- }
- let mRole = member.guild.roles.cache.get(settings.mutedRole)
- if (!mRole) {
- return;
- };
- await member.roles.add(mRole.id).catch(console.error);
- if (settings.chatlogsChannel !== "off") {
- const channel = member.guild.channels.cache.find(
- channel => channel.name === settings.chatlogsChannel
- );
-
- if (channel) {
- let embed = new Discord.MessageEmbed();
- embed.setColor("#1f1f1f");
- embed.setAuthor("User automatically muted:", member.user.avatarURL({dynamic: true}));
- embed.setDescription(`❯ User: ${member} (${member.user.id})`, true);
- embed.setFooter(`New users are being automatically muted because raidmode is enabled.`)
- try {
- channel.send(embed);
- } catch (err) {
- // probably no permissions to send messages/embeds there
- };
- };
- };
-};
-
- if (settings.chatlogsChannel !== "off") {
- const channel = member.guild.channels.cache.find(
- channel => channel.name === settings.chatlogsChannel
- );
-
- if (channel) {
- let embed = new Discord.MessageEmbed();
- embed.setColor("#0099e1");
- embed.setAuthor("User joined:", member.user.avatarURL({dynamic: true}));
- embed.setDescription(`❯ User: ${member} (${member.user.id})`, true);
- try {
- channel.send({ embed });
- } catch (err) {
- // probably no permissions to send messages/embeds there
- };
- };
- };
-
-};
diff --git a/src/events/guildMemberRemove.js b/src/events/guildMemberRemove.js
deleted file mode 100644
index b632ef1..0000000
--- a/src/events/guildMemberRemove.js
+++ /dev/null
@@ -1,36 +0,0 @@
-module.exports = async (client, member) => {
- const settings = client.getSettings(member.guild.id);
-
- if (settings.leaveMessage !== "off") {
- let chanExists = member.guild.channels.cache.get(settings.welcomeChannel)
- if (!chanExists) {
- return;
- };
- leaveMessage = settings.leaveMessage.replace("[[user]]", member.user);
- leaveMessage = leaveMessage.replace("[[server]]", member.guild.name);
- leaveMessage = leaveMessage.replace("[[members]]", member.guild.memberCount);
-
- member.guild.channels
- .cache.get(settings.welcomeChannel)
- .send(leaveMessage)
- .catch(console.error);
- };
-
- if (settings.chatlogsChannel !== "off") {
- const channel = member.guild.channels.cache.find(
- channel => channel.name === settings.chatlogsChannel
- );
-
- if (channel) {
- let embed = new Discord.MessageEmbed();
- embed.setColor("#006798");
- embed.setAuthor("User left:", member.user.avatarURL({dynamic: true}));
- embed.setDescription(`❯ ${member.user.tag} (${member.user.id})`, true);
- try {
- channel.send({ embed });
- } catch (err) {
- // probably no permissions to send messages/embeds there
- };
- };
- };
-};
diff --git a/src/events/message.js b/src/events/message.js
deleted file mode 100644
index 7c399a8..0000000
--- a/src/events/message.js
+++ /dev/null
@@ -1,235 +0,0 @@
-const cooldown = new Set();
-module.exports = async (client, message) => {
- if (message.author.bot) return;
-
- var settings;
-
- if(message.guild) {
- settings = message.settings = client.getSettings(message.guild.id) || client.defaultSettings;
- } else {
- settings= client.config.defaultSettings;
- }
-
- var prefix = settings.prefix;
-
- if(client.devmode == true) {
- prefix = settings.devprefix;
- }
-
- let blacklisted = false;
-
- if(message.guild) {
-
- perms = message.channel.permissionsFor(client.user);
-
- var modRole = message.guild.roles.cache.get(settings.modRole);
- var adminRole = message.guild.roles.cache.get(settings.adminRole);
- var autorole = message.guild.roles.cache.get(settings.autorole);
- var mutedRole = message.guild.roles.cache.get(settings.mutedRole);
- var welcomeChannel = message.guild.channels.cache.get(settings.welcomeChannel);
-
- if(!welcomeChannel && settings.welcomeChannel != "off" || !adminRole && settings.adminRole != "None set" || !modRole && settings.modRole != "None set" || !mutedRole && settings.mutedRole != "None set" || !autorole && settings.autorole != "off") {
-
- var adminReset = false;
- var modReset = false;
- var mutedReset = false;
- var autoReset = false;
- var welcomeReset = false;
-
- if(!adminRole && settings.adminRole != "None set") {
- var role = message.guild.roles.cache.find(r => r.name === settings.adminRole);
- if(!role) {
- adminReset = true;
- client.settings.set(message.guild.id, client.config.defaultSettings.adminRole, "adminRole");
- } else {
- client.settings.set(message.guild.id, role.id, "adminRole");
- };
- };
-
- if(!mutedRole && settings.mutedRole != "None set") {
- var role = message.guild.roles.cache.find(r => r.name === settings.mutedRole);
- if(!role) {
- mutedReset = true;
- client.settings.set(message.guild.id, client.config.defaultSettings.mutedRole, "mutedRole");
- } else {
- client.settings.set(message.guild.id, role.id, "mutedRole");
- };
- };
-
- if(!modRole && settings.modRole != "None set") {
- var role = message.guild.roles.cache.find(r => r.name === settings.modRole);
- if(!role) {
- modReset = true;
- client.settings.set(message.guild.id, client.config.defaultSettings.modRole, "modRole");
- } else {
- client.settings.set(message.guild.id, role.id, "modRole");
- };
- };
-
- if(!autorole && settings.autorole != "off") {
- var role = message.guild.roles.cache.find(r => r.name === settings.autorole);
- if(!role) {
- autoReset = true;
- client.settings.set(message.guild.id, client.config.defaultSettings.autorole, "autorole");
- } else {
- client.settings.set(message.guild.id, role.id, "autorole");
- };
- };
-
- if(!welcomeChannel && settings.welcomeChannel != "off") {
- var channel = message.guild.channels.cache.find(c => c.name === settings.welcomeChannel);
- if(!channel) {
- welcomeReset = true;
- client.settings.set(message.guild.id, client.config.defaultSettings.welcomeChannel, "welcomeChannel");
- } else {
- client.settings.set(message.guild.id, channel.id, "welcomeChannel");
- };
- };
-
- var errors = "";
- if(adminReset == true) {
- adminReset = false;
- errors += ", `admin role`";
- };
-
- if(modReset == true) {
- modReset = false;
- errors += ", `mod role`";
- };
-
- if(mutedReset == true) {
- mutedReset = false;
- errors += ", `muted role`";
- };
-
- if(autoReset == true) {
- autoReset = false;
- errors += ", `autorole`";
- };
-
- if(welcomeReset == true) {
- welcomeReset = false;;
- errors += ", `join/leave channel`";
- };
-
- if(errors.length > 1) {
- var errors = errors.substr(2);
- message.channel.send(`<:error:466995152976871434> A role or channel was deleted, and the following settings have been restored to their default values: ${errors}`);
- };
- };
-
- if (!message.member) {
- await message.guild.members.fetch(message.author);
- };
-
- if(message.settings.blacklisted != "ARRAY" && settings.blacklisted.length > 0) {
- settings.blacklisted.forEach(function(ID) {
- if(ID == message.author.id) {
- blacklisted = true;
- }
- });
- };
- };
-
- //const prefixMention = new RegExp(`^<@!?${client.user.id}>( |)$`);
- const myMention = `<@&${client.user.id}>`;
- const myMention2 = `<@!${client.user.id}>`;
-
- if (message.content.startsWith(myMention) || message.content.startsWith(myMention2)) {
- if(message.content.length > myMention.length + 1 && (message.content.substr(0, myMention.length + 1) == myMention + ' ' || message.content.substr(0, myMention2.length + 1) == myMention2 + ' ')) {
- prefix = message.content.substr(0, myMention.length) + ' ';
- } else {
- return message.channel.send(`Current prefix: \`${prefix}\``);
- };
- };
-
- if (message.content.indexOf(prefix) !== 0) return;
-
- const args = message.content.slice(prefix.length).trim().split(/ +/g);
- const command = args.shift().toLowerCase();
- const cmd = client.commands.get(command) || client.commands.get(client.aliases.get(command));
-
- if (!cmd) return;
-
- if (cooldown.has(message.author.id)) {
- return message.channel.send(
- `⏱️ You are being ratelimited. Please try again in 2 seconds.`
- ).then(msg => {
- msg.delete({timeout: 2000});
- });
- };
-
- if (message.guild && !perms.has('SEND_MESSAGES')) {
- return message.author.send(`<:error:466995152976871434> I don't have permission to speak in **#${message.channel.name}**, Please ask a moderator to give me the send messages permission!`);
- };
-
- if(message.guild && blacklisted == true) {
- try {
- return message.author.send(
- `<:denied:466995195150336020> You have been blacklisted from using commands in \`${message.guild.name}\``
- );
- } catch(err) {
- client.logger.log(err, "error")
- };
- };
-
- if (cmd && !message.guild && cmd.conf.guildOnly)
- return message.channel.send("<:denied:466995195150336020> This command is unavailable in DM's. Try running it in a server I'm in!");
-
- if (message.guild) {
- var missing = cmd.conf.requiredPerms.filter(p => !perms.has(p))
- if(missing.length > 0) {
- missing = "`" + (missing.join("`, `")) + "`";
- return message.channel.send(`<:error:466995152976871434> Missing permissions: ${missing}`)
- };
- };
-
- const level = client.permlevel(message);
-
- if(cmd.conf.permLevel == "Developer") {
- var isDeveloper;
- if(message.client.config.owners.includes(message.author.id)) {
- isDeveloper = true;
- }
- if(isDeveloper != true) {
- return message.channel.send("<:denied:466995195150336020> This command can only be used by my developers!")
- }
- }
-
- if (level < client.levelCache[cmd.conf.permLevel]) {
- var usrlvl = client.levelCache[cmd.conf.permLevel];
- if (usrlvl === 1) var displevel = "Moderator";
- if (usrlvl === 2) var displevel = "Administrator";
- if (usrlvl === 3) var displevel = "Server Owner";
-
- if (!modRole && usrlvl < 2 && cmd.conf.permLevel == "Moderator" && message.guild) {
- return message.channel.send("<:error:466995152976871434> No moderator role set! Please ask the server owner to set one with `" + message.settings.prefix + "modrole `")
- }
-
- if (!adminRole && usrlvl < 3 && cmd.conf.permLevel == "Administrator" && message.guild) {
- return message.channel.send("<:error:466995152976871434> No administrator role set! Please ask the server owner to set one with `" + message.settings.prefix + "adminrole `")
- }
-
- var englesh = "a";
- if (displevel === "Administrator") englesh = "an";
- if (displevel === "Server Owner") englesh = "the";
- return message.channel.send(`<:denied:466995195150336020> You need to be ${englesh} ${displevel} to run this command!`);
- }
-
- message.author.permLevel = level;
-
- message.flags = [];
- while (args[0] && args[0][0] === "-") {
- message.flags.push(args.shift().slice(1));
- };
-
- cooldown.add(message.author.id);
-
- setTimeout(() => {
- cooldown.delete(message.author.id);
- }, 2000);
-
- client.logger.cmd(`${client.config.permLevels.find(l => l.level === level).name} ${message.author.username} (${message.author.id}) ran command ${cmd.help.name}`);
-
- cmd.run(client, message, args, level);
-};
diff --git a/src/events/messageDelete.js b/src/events/messageDelete.js
deleted file mode 100644
index c697f3e..0000000
--- a/src/events/messageDelete.js
+++ /dev/null
@@ -1,40 +0,0 @@
-const Discord = require("discord.js");
-
-module.exports = (client, message) => {
- if (message.author.bot) return;
-
- const settings = (message.settings = client.getSettings(message.guild.id));
-
- if (settings.chatlogsChannel !== "off") {
- const channel = message.guild.channels.cache.find(
- channel => channel.name === settings.chatlogsChannel
- )
-
- var msg = message.content;
-
- if(!message.member) {
- return;
- }
-
- if(msg.length + message.member.user.username.length + message.member.user.id.length + message.channel.name.length + 2 > 2048) {
- return;
- }
-
- if (channel) {
- let embed = new Discord.MessageEmbed();
- embed.setColor("#f93a2f");
- embed.setAuthor("Message deleted!", message.member.user.avatarURL({dynamic: true}));
- if (msg == "") {
- msg = "**An image was deleted, but is not shown for privacy reasons.**"
- } else {
- msg = `\`${msg}\``
- }// image-only; maybe we can add image logging too but depends privacy (if someone sends like personal stuff accidentally)
- embed.setDescription(`❯ Author: ${message.member} (${message.member.user.id})\n❯ Channel: ${message.channel}\n❯ Message: ${msg}`)
- try {
- channel.send({ embed });
- } catch (err) {
- // probably no permissions to send messages/embeds there
- };
- };
- };
-};
diff --git a/src/events/messageUpdate.js b/src/events/messageUpdate.js
deleted file mode 100644
index c6aa6e8..0000000
--- a/src/events/messageUpdate.js
+++ /dev/null
@@ -1,40 +0,0 @@
-const Discord = require("discord.js");
-
-module.exports = (client, omsg, nmsg) => {
- if (nmsg.content === omsg.content) return;
-
- const settings = (omsg.settings = nmsg.settings = client.getSettings(
- nmsg.guild.id
- ));
-
- if (settings.chatlogsChannel !== "off") {
- const channel = nmsg.guild.channels.cache.find(
- channel => channel.name === settings.chatlogsChannel
- );
-
- if (channel) {
- let embed = new Discord.MessageEmbed();
- embed.setColor("#fff937");
- embed.setAuthor("Message Edited!", nmsg.member.user.avatarURL({dynamic: true}));
- if (omsg.content == "") {
- omsg.content = "**[IMAGE]**"
- } else if (nmsg.content == "") {
- nmsg.content = `**[IMAGE]**`
- } else {
- omsg.content = `\`${omsg.content}\``
- nmsg.content = `\`${nmsg.content}\``
- }
-
- if(omsg.content.length + nmsg.content.length + nmsg.member.user.username.length + nmsg.member.user.id.length + nmsg.channel.name.length + 2 > 2048) {
- return;
- }
-
- embed.setDescription(`• Author: ${nmsg.member} (${nmsg.member.user.id})\n• Channel: ${nmsg.channel}\n• Old message: ${omsg.content}\n• New message: ${nmsg.content}`)
- try {
- channel.send({ embed });
- } catch (err) {
- // probably no permissions to send messages/embeds there
- };
- };
- };
-};
diff --git a/src/events/ready.js b/src/events/ready.js
deleted file mode 100644
index 532cd8c..0000000
--- a/src/events/ready.js
+++ /dev/null
@@ -1,60 +0,0 @@
-const moment = require("moment");
-module.exports = client => {
-
- const timestamp = `${moment().format("YYYY-MM-DD HH:mm:ss")}`;
- const activityArray = client.commands.keyArray();
-
- client.lockActivity = false;
-
- let guild, channel, channel1;
-
- if(client.config.loggingServer.length > 0) {
- try {
- guild = client.guilds.cache.get(client.config.loggingServer)
- } catch(err) {
- client.logger.error("Could not find loggingServer server (is the ID valid?):\n" + err);
- process.exit(1);
- };
-
- if(client.config.consoleLogs.length > 0) {
- try {
- channel1 = guild.channels.cache.get(client.config.consoleLogs)
- } catch(err) {
- client.logger.error("Could not find consoleLogs channel (is the ID valid?):\n" + err);
- process.exit(1);
- };
- };
-
- if(client.config.startupLogs.length > 0) {
- try {
- channel = guild.channels.cache.get(client.config.startupLogs)
- } catch(err) {
- client.logger.error("Could not find startupLogs channel (is the ID valid?):\n" + err);
- process.exit(1);
- };
- };
- };
-
- if(client.devmode == true) {
- client.logger.warn("Running in development mode.")
- prefix = client.config.defaultSettings.devprefix;
- } else {
- prefix = client.config.defaultSettings.prefix;
- if(channel) {
- channel.send(`Bot started at \`${timestamp}\``);
- };
- };
-
- let randomActivity = activityArray.random();
-
- client.user.setActivity(`${prefix + randomActivity} | v${client.version.number}`, {type: "PLAYING"});
-
- setInterval(() => {
- randomActivity = activityArray.random();
- if(client.lockActivity == false) {
- client.user.setActivity(`${prefix + randomActivity} | v${client.version.number}`, {type: "PLAYING"});
- };
- }, 30000);
-
- client.logger.log(`Connected to Discord as ${client.user.tag} | v${client.version.number}`, 'ready');
-};
diff --git a/src/modules/Logger.js b/src/modules/Logger.js
deleted file mode 100644
index e924961..0000000
--- a/src/modules/Logger.js
+++ /dev/null
@@ -1,90 +0,0 @@
-const chalk = require("chalk");
-const moment = require("moment");
-
-exports.log = (content, type = "log") => {
- const timestamp = `[${moment().format("YYYY-MM-DD HH:mm:ss")}]`;
-
- let channel;
-
- try {
- channel = client.guilds.cache.get(client.config.loggingServer).channels.cache.get(client.config.consoleLogs);
- } catch(err) {};
-
- var logToServer = false;
-
- if(client.devmode === false && channel && client.guilds.cache.get(client.config.loggingServer).available) {
- logToServer = true;
- };
-
- switch (type) {
- case "info": {
- try {
- if (logToServer == true) {
- channel.send(`\`${timestamp}\` \`[${type.toUpperCase()}]\` ` + content);
- };
- } catch(err) {};
- return console.log(`${timestamp} ${chalk.cyanBright(`[${type.toUpperCase()}]`)} ${content} `);
- };
-
- case "warn": {
- try {
- if (logToServer == true) {
- channel.send(`\`${timestamp}\` \`[${type.toUpperCase()}]\` ` + content);
- };
- } catch(err) {};
- return console.log(`${timestamp} ${chalk.yellowBright(`[${type.toUpperCase()}]`)} ${content} `);
- };
-
- case "error": {
- try {
- if (logToServer == true) {
- channel.send(`\`${timestamp}\` \`[${type.toUpperCase()}]\` ` + content);
- };
- } catch(err) {}
- return console.log(`${timestamp} ${chalk.redBright(`[${type.toUpperCase()}]`)} ${content} `);
- };
-
- case "debug": {
- try {
- if (logToServer == true) {
- channel.send(`\`${timestamp}\` \`[${type.toUpperCase()}]\` ` + content);
- };
- } catch(err) {};
- return console.log(`${timestamp} ${chalk.magentaBright(`[${type.toUpperCase()}]`)} ${content} `);
- };
-
- case "cmd": {
- try {
- if (logToServer == true) {
- channel.send(`\`${timestamp}\` \`[${type.toUpperCase()}]\` ` + content);
- };
- } catch(err) {};
- return console.log(`${timestamp} ${chalk.whiteBright(`[${type.toUpperCase()}]`)} ${content}`);
- };
-
- case "ready": {
- try {
- if (logToServer == true) {
- channel.send(`\`${timestamp}\` \`[${type.toUpperCase()}]\` ` + content);
- };
- } catch(err) {};
- return console.log(`${timestamp} ${chalk.greenBright (`[${type.toUpperCase()}]`)} ${content}`);
- };
-
- default: throw new TypeError("Logger type must be either warn, debug, info, ready, cmd or error.");
- };
-};
-
-exports.error = (...args) => this.log(...args, "error");
-
-exports.warn = (...args) => this.log(...args, "warn");
-
-exports.debug = (...args) => this.log(...args, "debug");
-
-exports.info = (...args) => this.log(...args, "info");
-
-exports.cmd = (...args) => this.log(...args, "cmd");
-
-exports.setClient = function(c) {
- client = c;
-};
diff --git a/src/modules/functions.js b/src/modules/functions.js
deleted file mode 100644
index a30dd4b..0000000
--- a/src/modules/functions.js
+++ /dev/null
@@ -1,382 +0,0 @@
-const ytdl = require('ytdl-core-discord');
-const youtubeInfo = require('youtube-info');
-const getYoutubeId = require('get-youtube-id');
-const fetch = require('node-fetch');
-
-module.exports = client => {
- // Permission level function
- client.permlevel = message => {
- let permlvl = 0;
-
- const permOrder = client.config.permLevels
- .slice(0)
- .sort((p, c) => (p.level < c.level ? 1 : -1));
-
- while (permOrder.length) {
- const currentLevel = permOrder.shift();
- if (message.guild && currentLevel.guildOnly) continue;
- if (currentLevel.check(message)) {
- permlvl = currentLevel.level;
- break;
- }
- }
- return permlvl;
- };
-
- // Guild settings function
- client.getSettings = guild => {
- const defaults = client.config.defaultSettings || {};
- if (!guild) return defaults;
- const guildData = client.settings.get(guild) || {};
- const returnObject = {};
- Object.keys(defaults).forEach(key => {
- returnObject[key] = guildData[key] ? guildData[key] : defaults[key];
- });
- return returnObject;
- };
-
- // Single line await messages
- client.awaitReply = async (msg, question, limit = 60000) => {
- const filter = m => m.author.id === msg.author.id;
- await msg.channel.send(question);
- try {
- const collected = await msg.channel.awaitMessages(filter, {
- max: 1,
- time: limit,
- errors: ["time"]
- });
- return collected.first().content;
- } catch (e) {
- return false;
- }
- };
-
- // Message clean function
- client.clean = async (client, text) => {
- if (text && text.constructor.name == "Promise") text = await text;
- if (typeof evaled !== "string")
- text = require("util").inspect(text, { depth: 1 });
-
- text = text
- .replace(/`/g, "`" + String.fromCharCode(8203))
- .replace(/@/g, "@" + String.fromCharCode(8203))
- .replace(
- client.token,
- "NaKzDzgwNDef1Nitl3YmDAy.tHEvdg.r34L.whl7sTok3N.18n4Ryj094p"
- );
-
- return text;
- };
-
- client.loadCommand = commandName => {
- try {
- const props = require(`../commands/${commandName}`);
- if (props.init) {
- props.init(client);
- }
- client.commands.set(props.help.name, props);
- props.conf.aliases.forEach(alias => {
- client.aliases.set(alias, props.help.name);
- });
- return false;
- } catch (e) {
- return `Failed to load command ${commandName}: ${e}`;
- };
- };
-
- client.unloadCommand = async commandName => {
- let command;
- if (client.commands.has(commandName)) {
- command = client.commands.get(commandName);
- } else if (client.aliases.has(commandName)) {
- command = client.commands.get(client.aliases.get(commandName));
- };
- if (!command)
- return `<:error:466995152976871434> The command \`${commandName}\` could not be found.`;
-
- if (command.shutdown) {
- await command.shutdown(client);
- };
- const mod = require.cache[require.resolve(`../commands/${commandName}`)];
- delete require.cache[require.resolve(`../commands/${commandName}.js`)];
- for (let i = 0; i < mod.parent.children.length; i++) {
- if (mod.parent.children[i] === mod) {
- mod.parent.children.splice(i, 1);
- break;
- };
- };
- return false;
- };
-
- // MEMBER SEARCH
- client.searchForMembers = function(guild, query) {
- if (!query) return;
- query = query.toLowerCase();
-
- var a = [];
- var b;
-
- try {
- b = guild.members.cache.find(x => x.displayName.toLowerCase() == query);
- if (!b) guild.members.cache.find(x => x.user.username.toLowerCase() == query);
- } catch (err) {};
- if (b) a.push(b);
- guild.members.cache.forEach(member => {
- if (
- (member.displayName.toLowerCase().startsWith(query) ||
- member.user.tag.toLowerCase().startsWith(query)) &&
- member.id != (b && b.id)
- ) {
- a.push(member);
- };
- });
- return a;
- };
-
- // USER OBJECT FROM MENTION
- client.getUserFromMention = mention => {
- if (!mention) return;
-
- if (mention.startsWith('<@') && mention.endsWith('>')) {
- mention = mention.slice(2, -1);
-
- if (mention.startsWith('!')) {
- mention = mention.slice(1);
- }
-
- return client.users.cache.get(mention);
- }
- }
-
-
- // MUSIC
- client.music = {guilds: {}};
-
- client.music.isYoutubeLink = function(input) {
- return input.startsWith('https://www.youtube.com/') || input.startsWith('http://www.youtube.com/') || input.startsWith('https://youtube.com/') || input.startsWith('http://youtube.com/') || input.startsWith('https://youtu.be/') || input.startsWith('http://youtu.be/') || input.startsWith('http://m.youtube.com/') || input.startsWith('https://m.youtube.com/');
- }
-
- client.music.search = async function(query)
- {
- return new Promise(function(resolve, reject)
- {
- try{
- fetch("https://www.googleapis.com/youtube/v3/search?part=id&type=video&q=" + encodeURIComponent(query) + "&key=" + client.config.ytkey)
- .then(res => res.json())
- .then(json => {
- if(!json.items) { reject(); return; }
- resolve(json.items[0]);
- });
- } catch (err) {
- client.logger.error("Music search err: ", err);
- throw err;
- };
- });
- }
-
- client.music.getGuild = function(id)
- {
- if(client.music.guilds[id]) return client.music.guilds[id];
-
- return client.music.guilds[id] =
- {
- queue: [],
- playing: false,
- paused: false,
- dispatcher: null,
- skippers: []
- }
- }
-
- client.music.getMeta = async function(id)
- {
- return new Promise(function(resolve, reject)
- {
- youtubeInfo(id, function(err, videoInfo)
- {
- if(err) throw err;
-
- resolve(videoInfo);
- });
- });
- }
-
- client.music.play = async function(message, input, bypassQueue)
- {
- let voiceChannel = message.member.voice.channel;
- if(!voiceChannel) return message.channel.send('<:error:466995152976871434> You need to be in a voice channel to use this command!');
-
- let permissions = voiceChannel.permissionsFor(client.user);
- if (!permissions.has('CONNECT')) {
- return message.channel.send('<:error:466995152976871434> I do not have permission to join your voice channel.');
- }
- if (!permissions.has('SPEAK')) {
- return message.channel.send('<:error:466995152976871434> I do not have permission to join your voice channel.');
- }
- if (voiceChannel.joinable != true) {
- return message.channel.send("<:error:466995152976871434> I do not have permission to join your voice channel.")
- }
-
- let id = undefined;
-
- if(client.music.isYoutubeLink(input))
- {
- id = await getYoutubeId(input)
- } else {
- let item = await client.music.search(input);
- if(!item) {
- return message.channel.send(`<:error:466995152976871434> No results found.`);
- };
- id = item.id.videoId;
- }
-
- if(client.music.getGuild(message.guild.id).queue.length == 0 || bypassQueue)
- {
- let meta = await client.music.getMeta(id);
-
- if(!bypassQueue) client.music.getGuild(message.guild.id).queue.push({input: input, id: id, requestedBy: message.author, title: meta.title, author: meta.owner, thumbnail: meta.thumbnailUrl, duration: meta.duration});
-
- let connection = await new Promise((resolve, reject) =>
- {
- voiceChannel.join().then((connection) =>
- {
- resolve(connection);
- });
- });
-
- function end(silent)
- {
- client.music.getGuild(message.guild.id).queue.shift();
- client.music.getGuild(message.guild.id).dispatcher = null;
-
- if(client.music.getGuild(message.guild.id).queue.length > 0)
- {
- client.music.play(message, client.music.getGuild(message.guild.id).queue[0].input, true);
- } else {
- client.music.getGuild(message.guild.id).playing = false;
-
- if(!silent) {
- message.channel.send("<:play:467216788187512832> Queue is empty! Disconnecting from the voice channel.");
- }
-
- connection.disconnect();
- }
- }
-
- client.music.getGuild(message.guild.id).playing = true;
-
- let song = client.music.getGuild(message.guild.id).queue[0];
-
- try
- {
- let dispatcher = client.music.getGuild(message.guild.id).dispatcher = connection.play(await ytdl("https://www.youtube.com/watch?v=" + id, {highWaterMark: 1024 * 1024 * 32}), {type: 'opus'});
-
- dispatcher.on('finish', (a, b) =>
- {
- end(a == "silent");
- });
- } catch(err) {
- message.channel.send('<:error:466995152976871434> Failed to play **' + song.title + '** ' + err);
-
- end();
- }
-
- client.music.getGuild(message.guild.id).skippers = [];
- message.channel.send(`<:play:467216788187512832> Now playing: **${song.title}**`);
- } else {
- let meta = await client.music.getMeta(id);
- let song = {input: input, id: id, requestedBy: message.author, title: meta.title, author: meta.owner, thumbnail: meta.thumbnailUrl, duration: meta.duration};
-
- client.music.getGuild(message.guild.id).queue.push(song);
-
- message.channel.send(`<:success:466995111885144095> Added to queue: **${song.title}**`);
- }
- }
-
- // MUSIC - TIMESTAMP
- client.createTimestamp = function(duration){
- hrs = ~~(duration / 60 / 60),
- min = ~~(duration / 60) % 60,
- sec = ~~(duration - min * 60);
-
- if(String(hrs).length < 2) {
- hrs = "0" + String(hrs) + ":";
- };
-
- if(String(min).length < 2) {
- min = "0" + String(min);
- };
-
- if(String(sec).length < 2) {
- sec = "0" + String(sec);
- };
-
- if(hrs == "00:") {
- hrs = "";
- }
-
- var time = hrs + min + ":" + sec;
- return time;
- };
-
- //FIND ROLE
- client.findRole = function(input, message) {
- var role;
- role = message.guild.roles.cache.find(r => r.name.toLowerCase() === input.toLowerCase());
- if(!role) {
- role = message.guild.roles.cache.get(input.toLowerCase());
- };
-
- if(!role) {
- return;
- };
-
- return role;
- };
-
- // EMBED COLOUR
- client.embedColour = function(msg) {
- if(!msg.guild) {
- return ["#ff9d68", "#ff97cb", "#d789ff", "#74FFFF"].random();
- } else {
- return msg.guild.member(client.user).displayHexColor;
- };
- };
-
- // FIND RANDOM INT BETWEEN TWO INTEGERS
- client.intBetween = function(min, max){
- return Math.round((Math.random() * (max - min))+min);
- };
-
-
- // .toPropercase() returns a proper-cased string
- Object.defineProperty(String.prototype, "toProperCase", {
- value: function() {
- return this.replace(
- /([^\W_]+[^\s-]*) */g,
- txt => txt.charAt(0).toUpperCase() + txt.substr(1).toLowerCase()
- );
- }
- });
-
- // .random() returns a single random element from an array
- Object.defineProperty(Array.prototype, "random", {
- value: function() {
- return this[Math.floor(Math.random() * this.length)];
- }
- });
-
- // `await client.wait(1000);` to "pause" for 1 second.
- client.wait = require("util").promisify(setTimeout);
-
- // These 2 process methods will catch exceptions and give *more details* about the error and stack trace.
- process.on("uncaughtException", err => {
- const errorMsg = err.stack.replace(new RegExp(`${__dirname}/`, "g"), "./");
- client.logger.error(`Uncaught Exception: ${errorMsg}`);
- process.exit(1);
- });
-
- process.on("unhandledRejection", err => {
- client.logger.error(`Unhandled rejection: ${err.stack}`);
- });
-};
diff --git a/utils/_functions.js b/utils/_functions.js
new file mode 100644
index 0000000..4d01421
--- /dev/null
+++ b/utils/_functions.js
@@ -0,0 +1,293 @@
+/*
+ * Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+ * Some code found in this file has been taken from Guidebot, which is licensed under the MIT license.
+ */
+
+// Functions in this file are bound to the client object, and available basically anywhere.
+
+const { MessageEmbed } = require('discord.js')
+const mongoose = require('mongoose')
+const Guild = require('../models/guild')
+const User = require('../models/user')
+
+module.exports = client => {
+ // Creates an embed for when commands are used incorrectly
+ client.userError = (msg, cmd, err) => {
+ const embed = new MessageEmbed()
+ embed.setColor('#EF5350')
+ embed.setTitle(cmd.help.name + ':' + cmd.help.category.toLowerCase())
+ embed.setDescription(err)
+ embed.addField('**Usage**', cmd.help.usage)
+ embed.addField('**Parameters**', cmd.help.parameters)
+ embed.setFooter(`Run 'help ${cmd.help.name}' for more information.`)
+ msg.channel.send(embed).then(msg => {
+ msg.delete({ timeout: 60000 })
+ })
+ }
+
+ // Embed colour function
+ client.embedColour = function (guild) {
+ if (!guild || guild.member(client.user).displayHexColor === '#000000') {
+ return ['#ff9d68', '#ff97cb', '#d789ff', '#74FFFF'].random()
+ } else {
+ return guild.member(client.user).displayHexColor
+ }
+ }
+
+ // Clean up input to remove @everyone, token, etc
+ client.clean = async (client, text) => {
+ if (text && text.constructor.name === 'Promise') {
+ text = await text
+ }
+ if (typeof text !== 'string') {
+ text = require('util').inspect(text, { depth: 1 })
+ }
+ text = text
+ .replace(/`/g, '`' + String.fromCharCode(8203))
+ .replace(/@/g, '@' + String.fromCharCode(8203))
+ .replace(client.token, 'mfa.VkO_2G4Qv3T--NO--lWetW_tjND--TOKEN--QFTm6YGtzq9PH--4U--tG0')
+
+ return text
+ }
+
+ // Single line await messages
+ client.awaitReply = async (msg, question, limit = 60000) => {
+ const filter = m => m.author.id === msg.author.id
+ await msg.channel.send(question)
+ try {
+ const collected = await msg.channel.awaitMessages(filter, {
+ max: 1,
+ time: limit,
+ errors: ['time']
+ })
+ return collected.first().content
+ } catch (e) {
+ return false
+ }
+ }
+
+ // Capitalises the first letter of every word in a string
+ // eslint-disable-next-line no-extend-native
+ Object.defineProperty(String.prototype, 'toProperCase', {
+ value: function () {
+ return this.replace(/([^\W_]+[^\s-]*) */g, (txt) => txt.charAt(0).toUpperCase() + txt.substr(1).toLowerCase())
+ }
+ })
+
+ // Returns a random int between min and max
+ client.intBetween = function (min, max) {
+ return Math.floor((Math.random() * (max - min)) + min)
+ }
+
+ // Get random array object
+ // eslint-disable-next-line no-extend-native
+ Object.defineProperty(Array.prototype, 'random', {
+ value: function () {
+ return this[Math.floor(Math.random() * this.length)]
+ }
+ })
+
+ // `await client.wait(1000);` to 'pause' for 1 second.
+ client.wait = require('util').promisify(setTimeout)
+
+ // Find guild members
+ client.findMembers = function (guild, search) {
+ if (!search || typeof search !== 'string') return
+
+ const members = []
+ let member
+
+ // Try ID search
+ if (!isNaN(search) === true) {
+ members.push(guild.members.cache.get(search))
+ if (members[0]) {
+ return members[0]
+ }
+ }
+
+ // Try username search
+ try {
+ member = guild.members.cache.find(m => m.displayName.toLowerCase() === search)
+ if (!member) {
+ guild.members.cache.find(m => m.user.tag.toLowerCase() === search)
+ }
+ } catch (err) {}
+ if (member) {
+ members.push(member)
+ }
+ guild.members.cache.forEach(m => {
+ if (m.displayName.toLowerCase().startsWith(search) || m.user.tag.toLowerCase().startsWith(search)) {
+ members.push(m)
+ }
+ })
+
+ return members
+ }
+
+ // USER OBJECT FROM MENTION
+ client.getUserFromMention = mention => {
+ if (!mention) return
+
+ if (mention.startsWith('<@') && mention.endsWith('>')) {
+ mention = mention.slice(2, -1)
+
+ if (mention.startsWith('!')) {
+ mention = mention.slice(1)
+ }
+
+ return client.users.cache.get(mention)
+ }
+ }
+
+ client.findRole = function (guild, search) {
+ var role = guild.roles.cache.find(r => r.name.toLowerCase() === search.toLowerCase())
+ if (!role) {
+ role = guild.roles.cache.get(search.toLowerCase())
+ }
+
+ if (!role) {
+ return
+ }
+
+ return role
+ }
+
+ // Permission level function
+ client.permlevel = (message, settings) => {
+ let permlvl = 0
+
+ const permOrder = client.config.permLevels.slice(0).sort((p, c) => p.level < c.level ? 1 : -1)
+
+ while (permOrder.length) {
+ const currentLevel = permOrder.shift()
+ if (message.guild && currentLevel.guildOnly) continue
+ if (currentLevel.check(message, settings)) {
+ permlvl = currentLevel.level
+ break
+ }
+ }
+ return permlvl
+ }
+
+ // Get guild settings
+ client.findOrCreateGuild = async (guild) => {
+ const data = await Guild.findOne({ guildID: guild.id })
+ if (data) {
+ return data
+ } else {
+ const merged = Object.assign({ _id: mongoose.Types.ObjectId() }, { guildID: guild.id })
+ const newGuild = await new Guild(merged)
+ return newGuild.save()
+ }
+ }
+
+ // Update guild settings
+ client.updateGuild = async (guild, settings) => {
+ let data = await client.findOrCreateGuild(guild)
+
+ if (typeof data !== 'object') data = {}
+ for (const key in settings) {
+ if (data[key] !== settings[key]) {
+ data[key] = settings[key]
+ } else return
+ }
+
+ return data.updateOne(settings)
+ }
+
+ // Delete guild settings
+ client.deleteGuild = async (guild) => {
+ const data = await client.findOrCreateGuild(guild)
+ if (data) {
+ data.deleteOne({ guildID: guild.id })
+ }
+ }
+
+ // Get user settings
+ client.findOrCreateUser = async (user) => {
+ const data = await User.findOne({ userID: user.id })
+ if (data) {
+ return data
+ } else {
+ const merged = Object.assign({ _id: mongoose.Types.ObjectId() }, { userID: user.id })
+ const newUser = await new User(merged)
+ return newUser.save()
+ }
+ }
+
+ // Update user settings
+ client.updateUser = async (user, settings) => {
+ let data = await client.findOrCreateUser(user)
+
+ if (typeof data !== 'object') data = {}
+ for (const key in settings) {
+ if (data[key] !== settings[key]) {
+ data[key] = settings[key]
+ } else return
+ }
+
+ return data.updateOne(settings)
+ }
+
+ // Delete user settings
+ client.deleteUser = async (user) => {
+ const data = await client.findOrCreateUser(user)
+ if (data) {
+ data.deleteOne({ userID: user.id })
+ }
+ }
+
+ // Loads commands
+ client.loadCommand = (commandName) => {
+ try {
+ const props = require(`../commands/${commandName}`)
+ if (props.init) {
+ props.init(client)
+ }
+ client.commands.set(props.help.name, props)
+ // So commands can each have their own cooldown time
+ client.cooldown.set(props.help.name, new Map())
+ props.conf.aliases.forEach(alias => {
+ client.aliases.set(alias, props.help.name)
+ })
+ return false
+ } catch (e) {
+ return `Failed to load ${commandName}: ${e}`
+ }
+ }
+
+ // Command unloader
+ client.unloadCommand = async (commandName) => {
+ let command
+ if (client.commands.has(commandName)) {
+ command = client.commands.get(commandName)
+ } else if (client.aliases.has(commandName)) {
+ command = client.commands.get(client.aliases.get(commandName))
+ }
+ if (!command) return `The command \`${commandName}\` doesn't seem to exist, nor is it an alias. Try again!`
+
+ if (command.shutdown) {
+ await command.shutdown(client)
+ }
+ const mod = require.cache[require.resolve(`../commands/${command.help.name}`)]
+ delete require.cache[require.resolve(`../commands/${command.help.name}.js`)]
+ for (let i = 0; i < mod.parent.children.length; i++) {
+ if (mod.parent.children[i] === mod) {
+ mod.parent.children.splice(i, 1)
+ break
+ }
+ }
+ return false
+ }
+
+ // Both of these functions catch errors and log them (maybe we could use sentry?)
+ process.on('uncaughtException', (err) => {
+ const errorMsg = err.stack.replace(new RegExp(`${__dirname}/`, 'g'), './')
+ client.logger.error(`Uncaught Exception: ${errorMsg}`)
+ process.exit(1)
+ })
+
+ process.on('unhandledRejection', err => {
+ client.logger.error(`Unhandled rejection: ${err.stack}`)
+ })
+}
diff --git a/utils/botlists.js b/utils/botlists.js
new file mode 100644
index 0000000..b584297
--- /dev/null
+++ b/utils/botlists.js
@@ -0,0 +1,5 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+module.exports = client => {
+
+}
diff --git a/utils/logger.js b/utils/logger.js
new file mode 100644
index 0000000..d00045e
--- /dev/null
+++ b/utils/logger.js
@@ -0,0 +1,25 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+'use strict'
+
+const { colorConsole } = require('tracer')
+const colors = require('colors')
+
+const logger = colorConsole({
+ format: [
+ '{{timestamp}} | {{title}} | {{file}} | {{message}}',
+ {
+ debug: `{{timestamp}} | ${'{{title}}'.magenta} | {{file}} | {{message}}`,
+ cmd: `{{timestamp}} | ${'{{title}}'.white} | {{file}} | {{message}}`,
+ info: `{{timestamp}} | ${'{{title}}'.cyan} | {{file}} | {{message}}`,
+ ready: `{{timestamp}} | ${'{{title}}'.green} | {{file}} | {{message}}`,
+ warn: `{{timestamp}} | ${'{{title}}'.yellow} | {{file}} | {{message}}`,
+ error: `{{timestamp}} | ${'{{title}}'.red} | {{file}} | {{message}}`
+ }
+ ],
+ dateformat: 'yyyy-mm-dd"T"HH:MM:ss',
+ methods: ['cmd', 'debug', 'info', 'ready', 'warn', 'error'],
+ filters: [colors.white]
+})
+
+module.exports = logger
diff --git a/utils/mongoose.js b/utils/mongoose.js
new file mode 100644
index 0000000..186779e
--- /dev/null
+++ b/utils/mongoose.js
@@ -0,0 +1,38 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+const mongoose = require('mongoose')
+
+module.exports = {
+ init: (client) => {
+ const options = {
+ useNewUrlParser: true,
+ useUnifiedTopology: true,
+ autoIndex: false,
+ family: 4
+ }
+
+ try {
+ mongoose.connect(client.config.mongoDB, options)
+ mongoose.set('useFindAndModify', false)
+ mongoose.Promise = global.Promise
+ } catch (err) {
+ client.logger.error(`Could not connect to the database:\n ${err.stack}`)
+ }
+
+ mongoose.connection.on('connected', () => {
+ client.logger.info('Connected to the database.')
+ })
+
+ mongoose.connection.on('err', err => {
+ client.logger.error(`Database connection error:\n ${err.stack}`)
+ })
+
+ mongoose.connection.on('disconnected', () => {
+ client.logger.info('Disconected from the database.')
+ })
+
+ mongoose.connection.on('reconnected', () => {
+ client.logger.info('Reconnected to the database.')
+ })
+ }
+}
diff --git a/utils/music.js b/utils/music.js
new file mode 100644
index 0000000..fa01dec
--- /dev/null
+++ b/utils/music.js
@@ -0,0 +1,229 @@
+// Copyright 2020 Emily J. / mudkipscience and contributors. Subject to the AGPLv3 license.
+
+const ytdl = require('ytdl-core-discord')
+const fetch = require('node-fetch')
+const { MessageEmbed } = require('discord.js')
+const { utc } = require('moment')
+
+exports.queue = {}
+
+exports.createTimestamp = function (s) {
+ if (s < 1) {
+ return 'LIVE'
+ } else if (s >= 3600) {
+ return utc(s * 1000).format('HH:mm:ss')
+ } else {
+ return utc(s * 1000).format('mm:ss')
+ }
+}
+
+exports.getGuild = function (id) {
+ let guild = exports.queue[id]
+
+ if (!guild) {
+ guild = {}
+
+ guild.queue = []
+ guild.playing = false
+ guild.paused = false
+ guild.dispatcher = null
+ guild.skippers = []
+
+ exports.queue[id] = guild
+ }
+
+ return guild
+}
+
+exports.getLinkFromID = function (id) {
+ return 'https://www.youtube.com/watch?v=' + id
+}
+
+exports.getVideoByQuery = async function (client, query) {
+ let res
+
+ try {
+ const id = await ytdl.getURLVideoID(query)
+ res = await fetch(`${client.config.endpoints.invidious}v1/videos/${id}`)
+ } catch (err) {
+ res = await fetch(`${client.config.endpoints.invidious}v1/search?q=${encodeURIComponent(query)}`)
+ }
+
+ const parsed = await res.json()
+
+ if (parsed) {
+ const videos = parsed
+
+ if (videos) {
+ return videos
+ } else {
+ return false
+ }
+ } else {
+ return false
+ }
+}
+
+exports.play = async function (client, data, message, query, playNext, ignoreQueue) {
+ const guild = exports.getGuild(message.guild.id)
+ guild.message = message
+
+ if (!message.member.voice.channel && !guild.voiceChannel) {
+ return message.reply('You have to be connected to a voice channel to use this command!')
+ }
+
+ const vc = message.member.voice.channel
+
+ let video
+ let videos
+
+ if (!ignoreQueue) {
+ videos = await exports.getVideoByQuery(client, query)
+ if (!videos[1]) {
+ if (!videos[0]) {
+ video = videos
+ } else {
+ video = videos[0]
+ }
+ }
+ }
+
+ if (videos || ignoreQueue) {
+ if (!ignoreQueue) {
+ // Fix the bot if somehow broken
+ // music "playing", nothing in queue
+ if ((guild.playing || guild.dispatcher) && guild.queue.length === 0) {
+ guild.queue = []
+ guild.playing = false
+ guild.paused = false
+ guild.skippers = []
+ // music not playing, something is in queue
+ } else if (!guild.playing && !guild.dispatcher && guild.queue.length > 0) {
+ guild.queue = []
+ }
+
+ if (!video) {
+ let output = ''
+ let i = 0
+ for (i = 0; i < 5; i++) {
+ if (!videos[i]) break
+ output += `\`${i + 1}:\` **[${videos[i].title}](https://www.youtube.com/watch?v=${videos[i].videoId})** \`[${exports.createTimestamp(videos[i].lengthSeconds)}]\`\n`
+ }
+
+ const embed = new MessageEmbed()
+ embed.setTitle('Please reply with a number `1-' + i + '` to select which song you want to add to the queue.')
+ embed.setColor(client.embedColour(message.guild))
+ embed.setDescription(output)
+
+ let selection = await client.awaitReply(message, embed)
+ selection = Number(selection)
+
+ switch (selection) {
+ case 1:
+ video = videos[0]
+ break
+ case 2:
+ if (videos[1]) {
+ video = videos[1]
+ } else {
+ return message.channel.send('Invalid choice.')
+ }
+ break
+ case 3:
+ if (videos[2]) {
+ video = videos[2]
+ } else {
+ return message.channel.send('Invalid choice.')
+ }
+ break
+ case 4:
+ if (videos[3]) {
+ video = videos[3]
+ } else {
+ return message.channel.send('Invalid choice.')
+ }
+ break
+ case 5:
+ if (videos[4]) {
+ video = videos[4]
+ } else {
+ return message.channel.send('Invalid choice.')
+ }
+ break
+ default:
+ return message.channel.send('Invalid choice.')
+ }
+ }
+
+ if (!video && videos[0]) {
+ video = videos[0]
+ } else if (!video) {
+ video = videos
+ }
+
+ // Add video to queue
+ if (playNext === true) {
+ guild.queue.splice(1, 0, { video: video, requestedBy: message.author })
+ } else {
+ guild.queue.push({ video: video, requestedBy: message.author })
+ }
+ }
+
+ // Figure out if the bot should add it to queue or play it right now
+ if (guild.playing) {
+ message.reply('added **' + video.title + '** to the queue')
+ } else {
+ guild.playing = true
+
+ guild.voiceChannel = vc
+
+ if (!guild.channel) {
+ guild.channel = message.channel
+ }
+
+ const connection = await vc.join()
+
+ const v = guild.queue[0]
+
+ guild.dispatcher = connection.play(await ytdl(exports.getLinkFromID(v.video.videoId), { highWaterMark: 1024 * 1024 * 32 }), { type: 'opus' })
+ guild.dispatcher.setVolume(data.defaultVolume)
+
+ guild.channel.send('Playing **' + v.video.title + '**')
+
+ // play next in queue on end
+ guild.dispatcher.once('finish', () => {
+ guild.queue.shift()
+ guild.playing = false
+
+ if (guild.queue.length > 0) {
+ exports.play(client, data, message, null, false, true)
+ } else {
+ guild.queue = []
+ guild.playing = false
+ guild.paused = false
+ guild.skippers = []
+
+ connection.disconnect()
+ }
+ })
+ }
+ } else {
+ return message.reply('failed to find the video!')
+ }
+}
+
+exports.setVolume = function (guild, target) {
+ const g = exports.getGuild(guild.id)
+
+ if (g.dispatcher) {
+ g.dispatcher.setVolume(target)
+ }
+}
+
+exports.skip = function (guild, reason) {
+ const g = exports.getGuild(guild.id)
+
+ if (g.dispatcher) {
+ g.dispatcher.end(reason)
+ }
+}
diff --git a/version.json b/version.json
index 6d6b7a3..4142965 100644
--- a/version.json
+++ b/version.json
@@ -1,4 +1,5 @@
{
- "number": "1.2.3",
- "changelog": "**1.2.0 CHANGELOG:**\n> • Added action commands! (`cuddle`, `feed`, `hug`, `kiss`, `pat`, `poke`, `slap`, `smug`, `tickle`)\n> • Added `fact`\n> • Added `catfact`\n> • Added `dogfact`\n> • Added `yoda`\n> • Added `dice`\n> • Added `spoilerise`\n> • Added `zalgo`\n> • Added `dog`\n> • Added `cat`\n> • Added `lizard`\n> • Added `neko`\n> • Added `nekogif`\n> • Added `kemonomimi`\n> • Added `foxgirl`\n> • Added `identity`\n> • Added `pronouns`\n> • Added `sexuality`\n> • Added `ship`\n> • Renamed `flip to `coinflip` (flip remains as an alias)\n> • Renamed `math` to `calculate` (math is an alias)\n> • @Woomy is now a prefix\n> • Added the `inspire` alias to `inspirobot`\n> • Help now displays the amount of commands in each category\n> • Bots now get a badge in `userinfo`\n> • `roleinfo` now displays what permissions a role has\n> • small changes to `weather`\n> • Woomy now has clear logging of issues that prevent her from starting\n> • request npm module has been swapped out for node-fetch\n**NOTES:**\n> Thank you to Terryiscool160 for creating multiple commands used in this update"
-}
+ "number": "2.0",
+ "changelog": "uwu",
+ "news": "A massive update has just been released! Lots of commands and features have been added or redone and my code has been rewritten to use lots of cool new stuff. To view the full changelog, run `changelog`"
+}
\ No newline at end of file