Fixed restart to handle app state correctly

Signed-off-by: Ted Young <tyoung@pivotallabs.com>