The proper time between two events is defined as the time measured in the reference frame in which both events occur at the same location. For example, a rocket that travels from Earth to Mars measures the proper time of the journey because landing and taking off both occur at the same location relative to the rocket (this is obviously a massive simplification which ignores acceleration, amongst other things).
I have also read that the proper time between two events is also the shortest time between those two events that can be measured by any inertial reference frame.
Now, consider the example of a train moving at half the speed of light past an observer on a platform. We want to find the time it takes for the train to pass the observer (the two events would be the front and back of the train being in line with the observer). According to the definition of proper time above, the observer should measure the proper time because both events occur at the same location relative to him/her. This should mean that the observer records a shorter time between the two events than someone on the train would.
However, this is false and the scenario above is quite a common example in special relativity classes and lectures to demonstrate that the passenger on the train would actually measure proper time and the observer on the platform wouldn't.
Where am I going wrong here?