* WebAuthN: fix not working registration of new authentication devices or browsers

generally prefer app.min.js over old, pre RollupJS app.js
This commit is contained in:
ralf 2023-03-23 11:55:17 +01:00
parent 81eb6ccb6e
commit 4ec4ddb2a1

View File

@ -1479,6 +1479,13 @@ abstract class Framework extends Framework\Extra
*/
static function includeJS($package, $file=null, $app='api', $append=true)
{
// prefer app.min.js over old, pre RollupJS app.js
if ($package[0] === '/' && substr($package, -7) === '/app.js' &&
self::$js_include_mgr->include_js_file(substr($package, 0, -3).'.min.js', $file, $app, $append) ||
$file === 'app' && self::$js_include_mgr->include_js_file($package, 'app.min', $app, $append))
{
return;
}
self::$js_include_mgr->include_js_file($package, $file, $app, $append);
}