mirror of
https://github.com/Prowlarr/Prowlarr.git
synced 2025-09-26 20:11:49 +02:00
Updates cleanup
This commit is contained in:
26
src/UI/Handlebars/Helpers/System.js
Normal file
26
src/UI/Handlebars/Helpers/System.js
Normal file
@@ -0,0 +1,26 @@
|
||||
'use strict';
|
||||
|
||||
define(
|
||||
[
|
||||
'handlebars',
|
||||
'System/StatusModel'
|
||||
], function (Handlebars, StatusModel) {
|
||||
|
||||
Handlebars.registerHelper('if_windows', function(options) {
|
||||
if (StatusModel.get('isWindows'))
|
||||
{
|
||||
return options.fn(this);
|
||||
}
|
||||
|
||||
return options.inverse(this);
|
||||
});
|
||||
|
||||
Handlebars.registerHelper('if_linux', function(options) {
|
||||
if (StatusModel.get('isLinux'))
|
||||
{
|
||||
return options.fn(this);
|
||||
}
|
||||
|
||||
return options.inverse(this);
|
||||
});
|
||||
});
|
Reference in New Issue
Block a user