wiki.techinc.nl/includes/filerepo/TempFileRepo.php
Umherirrender 44fd53fee3 Using @return never documentation on always-throw-function
This helps phan to detect unreachable code and also impossible types
after the functions.
It helps phan to avoid false positives for array keys
when the keys are checked before

Bug: T240141
Change-Id: I895f70e82b3053a46cd44135b15437e6f82a07b2
2021-09-07 17:29:03 +02:00

10 lines
291 B
PHP

<?php
/**
* FileRepo for temporary files created via FileRepo::getTempRepo()
*/
class TempFileRepo extends FileRepo {
public function getTempRepo() {
// @phan-suppress-previous-line PhanPluginNeverReturnMethod
throw new MWException( "Cannot get a temp repo from a temp repo." );
}
}