function userError(UserException $e) { Logger::log('error', $e->getMessage(), (array) $e->getData()); exit(1); }