Skip to content

Commit

Permalink
Merge pull request #20 from nextcloud/fix-3rdparty-notice
Browse files Browse the repository at this point in the history
Print error message again, when 3rdparty submodule is not initialized
  • Loading branch information
blizzz committed Jun 8, 2016
2 parents 1aa7db5 + 39aeebf commit bc8fe82
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/base.php
Original file line number Diff line number Diff line change
Expand Up @@ -501,7 +501,9 @@ public static function init() {

} catch (\RuntimeException $e) {
if (!self::$CLI) {
OC_Response::setStatus(OC_Response::STATUS_SERVICE_UNAVAILABLE);
$claimedProtocol = strtoupper($_SERVER['SERVER_PROTOCOL']);
$protocol = in_array($claimedProtocol, ['HTTP/1.0', 'HTTP/1.1', 'HTTP/2']) ? $claimedProtocol : 'HTTP/1.1';
header($protocol . ' ' . OC_Response::STATUS_SERVICE_UNAVAILABLE);
}
// we can't use the template error page here, because this needs the
// DI container which isn't available yet
Expand Down

0 comments on commit bc8fe82

Please sign in to comment.