'Get all scripts in the database.
Args:
key (str, optional): Restrict result to only those
with matching key or dbref.
Returns:
scripts (list): All scripts found, or those matching `key`.'

@returns_typeclass_list
def get_all_scripts(self, key=None):

    if key:
        script = []
        dbref = self.dbref(key)
        if (dbref or (dbref == 0)):
            script = [res for res in [self.dbref_search(dbref)] if res]
        if (not script):
            script = self.filter(db_key=key)
        return script
    return self.all()
