Fix use new restart hook: never reset define