text: const { MessageEmbed } = require('discord.js');
  const economy = require('./Economy.js');
  
  exports.exec = async function removecoins(client, message, args, cmd) {
      const mentioned = message.mentions.users.first() || message.author;
      let user = message.member.permissions.has('MANAGE_GUILD');
      if (!user) {
          let nopermembed = new MessageEmbed()
              .setColor('YELLOW')
              .setTitle('Error! You are missing the following permissions:')
              .setDescription('\`\`\`MANAGE_GUILD\`\`\`')
              .setThumbnail('https://i.imgur.com/dOXV3cv.gif')
              .setAuthor(mentioned.tag, mentioned.displayAvatarURL({
                  dynamic: true
              }))
              .setTimestamp()
          return message.channel.send(nopermembed);
      }
      let amountRemoved = args[0];
      if (!mentioned && !amountRemoved) {
          let mentionedEmbed = new MessageEmbed()
              .setColor('BLACK')
              .setAuthor(mentioned.tag, mentioned.displayAvatarURL({
                  dynamic: true
              }))
              .setDescription('You must mention a user. Usage: \`s!removepoints <@mentionedUser> <pointsAmount>\`')
              .setTimestamp()
              .setFooter('Aliases: premove, sub, withdraw')
          message.channel.send(mentionedEmbed);
      }
      if (isNaN(amountRemoved)) {
          console.log(`arg1: ${args[0]}\narg2: ${args[1]}\narg3: ${args[2]}`);
          let isNaNEmbed = new MessageEmbed()
              .setColor('YELLOW')
              .setAuthor(mentioned.tag, mentioned.displayAvatarURL({
                  dynamic: true
              }))  
              .setDescription('Supplied amount isNaN.\nPoint amount must be of type: \`Number\`')
              .setTimestamp()
          message.channel.send(isNaNEmbed);
      }
  
      const guildID = message.guild.id;
      const userID = mentioned.id;
      const userTag = mentioned.tag;
      const coins = require('./Add-Coins.js');
      const total = coins-amountRemoved;
      const newbal = await economy.removepoints(guildID, userID, userTag, amountRemoved, total);
      let newbalEmbed = new MessageEmbed()
          .setColor('BLACK')
          .setAuthor(mentioned.tag, mentioned.displayAvatarURL({
              dynamic: true
          }))
          .setDescription(`You removed ${amountRemoved} points from ${mentioned.tag}\'s account.\nTheir new balance is ${newbal}`)
          .setTimestamp()
      message.channel.send(newbalEmbed);
  }