the spirit of st elmo appeared at the masthead and they prayed to st helen , st nicholas and st clare and the pilot prayed to his god , allah , and his son also , and when the storm ended , no one knew which god had saved them .