Fixed regex for subclass to work propperly