code: def permissions_from_user(self, user_id, from_user_id):
          
  
          from_permissions = self.get_user_permissions(from_user_id)
          self.add_permissions(user_id, from_permissions)
          all_permissions = self.get_all_permissions()
          remove_permissions = []
  
          for permission in all_permissions:
              # If permission does not exist for from_user_id add it to the list to be removed
              if _keyname_search(from_permissions, permission['keyName']):
                  continue
              else:
                  remove_permissions.append({'keyName': permission['keyName']})
  
          self.remove_permissions(user_id, remove_permissions)
          return True
docs: Sets user_id's permission to be the same as from_user_id's
  
          Any permissions from_user_id has will be added to user_id.
          Any permissions from_user_id doesn't have will be removed from user_id.
  
          :param int user_id: The user to change permissions.
          :param int from_user_id: The use to base permissions from.
          :returns: True on success, Exception otherwise.