diff --git a/controller/Controller.php b/controller/Controller.php index 39a5c8f74..21992b952 100644 --- a/controller/Controller.php +++ b/controller/Controller.php @@ -78,8 +78,7 @@ protected function negotiateFormat($choices, $accept, $format) // if there was no proposed format, negotiate a suitable format header('Vary: Accept'); // inform caches that a decision was made based on Accept header $best = $this->negotiator->getBest($accept, $choices); - $format = ($best !== null) ? $best->getValue() : null; - return $format; + return ($best !== null) ? $best->getValue() : null; } private function isSecure() @@ -106,8 +105,7 @@ private function guessBaseHref() $port = filter_input(INPUT_SERVER, 'SERVER_PORT', FILTER_SANITIZE_STRING); $disp_port = ($port == 80 || $port == 443) ? '' : ":$port"; $domain = filter_input(INPUT_SERVER, 'SERVER_NAME', FILTER_SANITIZE_STRING); - $full_url = "$protocol://{$domain}{$disp_port}{$base_url}"; - return $full_url; + return "$protocol://{$domain}{$disp_port}{$base_url}"; } public function getBaseHref() diff --git a/controller/Honeypot.php b/controller/Honeypot.php index 509e66d2c..917fc9a95 100644 --- a/controller/Honeypot.php +++ b/controller/Honeypot.php @@ -32,11 +32,10 @@ public function generate($honey_name, $honey_time) { // Encrypt the current time $honey_time_encrypted = $this->getEncryptedTime(); - $html = '