From 1d3c5d28e7d98b0e5387bc6ea7e0d01c083ee6e1 Mon Sep 17 00:00:00 2001 From: KRKeegan <-NOSPAM-kevin@krkeegan.com> Date: Thu, 28 Feb 2008 21:24:46 -0800 Subject: [PATCH] Prevent deletion of server section --- plugins/admin/templates/settings.tmpl | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/plugins/admin/templates/settings.tmpl b/plugins/admin/templates/settings.tmpl index 18bd3ea..7221d78 100644 --- a/plugins/admin/templates/settings.tmpl +++ b/plugins/admin/templates/settings.tmpl @@ -54,6 +54,10 @@ document.all.hideshow.divs[i].visibility = ''; } } function deleteSection(id){ +if (select_section.section.options[id].text == 'Global Server Settings'){ + alert('Delete Error:\n\nSorry the Global Server Settings Section is required for pyTivo to run and cannot be deleted'); + return true; +} var name = select_section.section.options[id].text; var answer = confirm("Are you sure you wish to delete the '" + name + "' Section?") if (answer){ -- 2.11.4.GIT