'Is Not Valid' but it seems to work?

where do i move this logic to then if not on the coin?