Properly fixed tmp/restart issue

Fix from https://github.com/nadarei/mina/pull/77 is incorrect. Fixing.