create($params['action']); $action->userData = $params; $action->execute(); } else { $showInactive = filter_input(INPUT_GET, 'show_inactive', FILTER_VALIDATE_BOOLEAN); echo BridgeList::create($showInactive); } } catch(\Exception $e) { error_log($e); $code = $e->getCode(); if ($code !== -1) { header('Content-Type: text/plain', true, $code); } die($e->getMessage()); }