I myself wanted him to lose to morty in first try and then win it in rematch instead of losing to whitney especially since that was his first time challenging ghost type specialist. Ash vs morty was the second best gym battle in johto after claire one.
IIRC, Morty was one of the most recurring Gym leaders in the Johto saga.