Fixed incorrect validation