fix the BaseCommand class and the pattern decorator