diff options
author | jenkins-bot <jenkins-bot@gerrit.wikimedia.org> | 2019-09-09 15:29:21 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@wikimedia.org> | 2019-09-09 15:29:21 +0000 |
commit | 1880c8401a0638be07a4fe5139ab425eb725e0ee (patch) | |
tree | 79a0011dd6b817cc56dfae33134ffa9fba01afe5 /includes/Setup.php | |
parent | 54c93f1d384cd5accd2db2ebbb911e4d627c2980 (diff) | |
parent | b7ce7aacb0fb6803d9135f465e9cf6b48912883e (diff) | |
download | mediawikicore-1880c8401a0638be07a4fe5139ab425eb725e0ee.tar.gz mediawikicore-1880c8401a0638be07a4fe5139ab425eb725e0ee.zip |
Merge "Add MW_REST_API and MW_ENTRY_POINT"
Diffstat (limited to 'includes/Setup.php')
-rw-r--r-- | includes/Setup.php | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/includes/Setup.php b/includes/Setup.php index cfb2ac16fa25..39f0c8116f6d 100644 --- a/includes/Setup.php +++ b/includes/Setup.php @@ -52,6 +52,17 @@ if ( ini_get( 'mbstring.func_overload' ) ) { die( 'MediaWiki does not support installations where mbstring.func_overload is non-zero.' ); } +// Define MW_ENTRY_POINT if it's not already, so that config code can check the +// value without using defined() +if ( !defined( 'MW_ENTRY_POINT' ) ) { + /** + * The entry point, which may be either the script filename without the + * file extension, or "cli" for maintenance scripts, or "unknown" for any + * entry point that does not set the constant. + */ + define( 'MW_ENTRY_POINT', 'unknown' ); +} + // Start the autoloader, so that extensions can derive classes from core files require_once "$IP/includes/AutoLoader.php"; |