mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Math
synced 2024-11-23 23:25:02 +00:00
Merge "Eliminate duplicate file"
This commit is contained in:
commit
f6832d0235
|
@ -102,8 +102,15 @@ class TexUtil {
|
|||
* @return array
|
||||
*/
|
||||
private function getJSON() {
|
||||
$file = file_get_contents( __DIR__ . '/texutil.json' );
|
||||
$file = self::getJsonFile();
|
||||
$json = json_decode( $file, true );
|
||||
return $json;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return false|string
|
||||
*/
|
||||
public static function getJsonFile() {
|
||||
return file_get_contents( __DIR__ . '/texutil.json' );
|
||||
}
|
||||
}
|
||||
|
|
|
@ -107,7 +107,7 @@ class TexUtilTest extends MediaWikiUnitTestCase {
|
|||
}
|
||||
|
||||
// Loading local json file
|
||||
$file = file_get_contents( __DIR__ . '/texutil.json' );
|
||||
$file = TexUtil::getJsonFile();
|
||||
$fileP = str_replace( [ "\n", "\t", " " ], "", $file );
|
||||
|
||||
$encP = json_encode( $out );
|
||||
|
|
File diff suppressed because it is too large
Load diff
Loading…
Reference in a new issue