Added missing include for std::runtime_error
Corrected initialization order