fix: Add restart to services and fix wireguard qrcode module
- haproxy: Add explicit restart_service function - tor-shield: Add explicit restart_service function - wireguard-dashboard/qrcode.js: Use baseclass.extend() pattern to fix "factory yields invalid constructor" error Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
fed7bd43c1
commit
b7edc32695
@ -1,4 +1,5 @@
|
|||||||
'use strict';
|
'use strict';
|
||||||
|
'require baseclass';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* QR Code Generator for WireGuard Dashboard
|
* QR Code Generator for WireGuard Dashboard
|
||||||
@ -443,7 +444,7 @@ function generateSVG(text, displaySize) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return {
|
return baseclass.extend({
|
||||||
/**
|
/**
|
||||||
* Generate QR code as SVG string
|
* Generate QR code as SVG string
|
||||||
* @param {string} text - Text to encode (up to ~300 bytes)
|
* @param {string} text - Text to encode (up to ~300 bytes)
|
||||||
@ -488,4 +489,4 @@ return {
|
|||||||
getMaxCapacity: function() {
|
getMaxCapacity: function() {
|
||||||
return VERSION_CAPACITIES[20]; // 858 bytes
|
return VERSION_CAPACITIES[20]; // 858 bytes
|
||||||
}
|
}
|
||||||
};
|
});
|
||||||
|
|||||||
@ -36,6 +36,11 @@ reload_service() {
|
|||||||
"$PROG" reload
|
"$PROG" reload
|
||||||
}
|
}
|
||||||
|
|
||||||
|
restart_service() {
|
||||||
|
stop
|
||||||
|
start
|
||||||
|
}
|
||||||
|
|
||||||
service_triggers() {
|
service_triggers() {
|
||||||
procd_add_reload_trigger "haproxy"
|
procd_add_reload_trigger "haproxy"
|
||||||
}
|
}
|
||||||
|
|||||||
@ -284,6 +284,11 @@ reload_service() {
|
|||||||
start
|
start
|
||||||
}
|
}
|
||||||
|
|
||||||
|
restart_service() {
|
||||||
|
stop
|
||||||
|
start
|
||||||
|
}
|
||||||
|
|
||||||
status() {
|
status() {
|
||||||
"$PROG" status
|
"$PROG" status
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user