App crash after restart fix