added cubit, removed inefficient check