Added method to check if it valid