Called AGameMode::RestartGame in PIE and exit PIE. Then the editor will crash

Called AGameMode::RestartGame in PIE and then pressed ESC to exit PIE. Then the editor will crash everytime.

Does the AGame::RestartGame was designed to not used in PIE?
Or is it a bug?

How can I Restar Current Game correctly?