registration: Allow the mtime of extension.json files to be zero
authorEd Schouten <ed@nuxi.nl>
Thu, 7 Jun 2018 12:21:53 +0000 (14:21 +0200)
committerKunal Mehta <legoktm@member.fsf.org>
Thu, 7 Jun 2018 17:58:40 +0000 (10:58 -0700)
commitd7d5d3c82a84338bd2669284427193ea7a80bdbc
tree50965ff65d62c8b73e9e6ffdde33ff63e58dba16
parent0e96bc1a9e5351931984b5bfc81d51a964d7123e
registration: Allow the mtime of extension.json files to be zero

When creating Docker images of MediaWiki using the Bazel build system, I
noticed that I'm not able to load any extensions. This is due to the
fact that Bazel always generates container layers with mtimes of files
set to 1970-01-01 for determinism/reproducibility.

Relax the check a bit to only fail when the mtime is false, which
happens when filemtime() fails.

Bug: T196672
Change-Id: Ieaeb3113a7d9c44f29cca2d062c5bb11ebeada0d
includes/registration/ExtensionRegistry.php