Why would he put a suitcase of dynamite under the hooker's bed?
The Jimmy Stewart character is in the brothel and still carrying a suitcase full of dynamite. He's been carrying it for some time and could have dropped it off anywhere. I would suggest he should have dropped it after getting off of the train.
But no. He brings it into the brothel and before they get into the boat he says, "I guess I can leave this here".
He leaves a suitcase full of dynamite under a prostitute's bed. A prostitute who he wants to accompany them and later goes back for because he fears she's been shot.
Why on earth would he leave the dynamite there? The only reason is because it sets up the later plot device of the madam shooting the suitcase and it detonating. That was also a weak point because she didn't check to see if there's any money in the suitcase until after they left. This is ridiculous.
Poor writing.