mirror of
https://github.com/pi-hole/web.git
synced 2026-05-08 17:49:49 +01:00
Skip version checks if on dev branch
This commit is contained in:
+6
-4
@@ -33,7 +33,8 @@ function versionCompare(left, right) {
|
||||
|
||||
// Update check
|
||||
$.getJSON("https://api.github.com/repos/pi-hole/pi-hole/releases/latest", function(json) {
|
||||
if(versionCompare(piholeVersion, json.tag_name.slice(1)) < 0) {
|
||||
// Skip if on dev
|
||||
if(piholeVersion !== "vDev" && versionCompare(piholeVersion, json.tag_name.slice(1)) < 0) {
|
||||
// Alert user
|
||||
$("#alPiholeUpdate").show();
|
||||
if(!$("#dropdown-menu").hasClass("open")) {
|
||||
@@ -42,7 +43,8 @@ $.getJSON("https://api.github.com/repos/pi-hole/pi-hole/releases/latest", functi
|
||||
}
|
||||
});
|
||||
$.getJSON("https://api.github.com/repos/pi-hole/AdminLTE/releases/latest", function(json) {
|
||||
if(versionCompare(webVersion, json.tag_name.slice(1)) < 0) {
|
||||
// Skip if on dev
|
||||
if(webVersion !== "vDev" && versionCompare(webVersion, json.tag_name.slice(1)) < 0) {
|
||||
// Alert user
|
||||
$("#alWebUpdate").show();
|
||||
if(!$("#dropdown-menu").hasClass("open")) {
|
||||
@@ -53,7 +55,7 @@ $.getJSON("https://api.github.com/repos/pi-hole/AdminLTE/releases/latest", funct
|
||||
|
||||
/*
|
||||
* Make sure that Pi-hole is updated to at least v2.7, since that is needed to use the sudo
|
||||
* features of the interface
|
||||
* features of the interface. Skip if on dev
|
||||
*/
|
||||
if(versionCompare(piholeVersion, "v2.7") < 0)
|
||||
if(piholeVersion !== "vDev" && versionCompare(piholeVersion, "v2.7") < 0)
|
||||
alert("Pi-hole needs to be updated to at least v2.7 before you can use features such as whitelisting/blacklisting from this web interface!")
|
||||
|
||||
Reference in New Issue
Block a user