Geordi didn't assume command, he was given command by his superior officer.
PICARD: Yes. Doctor Crusher, this is the Captain. Meet me in Transporter room three. Mister La Forge, you have command of the
LAFORGE: Aye, sir.
PICARD: And whatever happens down there, your prime responsibility is to the ship.
And although Logan has the superior rank, that doesn't mean that he can override the wishes of the Captain (by assuming command or attempting to give orders to La Forge) just because Picard is temporarily off the ship, any more than Lt. Commander Beverly Crusher can tell him how to run Engineering.
You might also wish to note that command rank is entirely in the gift of the Captain rather than being decided by simple rank, hence why Ensign Kim can run the Ops Dept. on the USS Voyager.