]> www.vanbest.org Git - motioneye-debian/commitdiff
minor modal title ui fix
authorCalin Crisan <ccrisan@gmail.com>
Thu, 3 Dec 2015 18:38:00 +0000 (20:38 +0200)
committerCalin Crisan <ccrisan@gmail.com>
Thu, 3 Dec 2015 18:38:00 +0000 (20:38 +0200)
motioneye/motionctl.py
motioneye/static/js/ui.js

index f3c6c7c2903bc0e19910209af4de026931a082e4..16b1370618f4d48f694e025a35ee3017e799a80b 100644 (file)
@@ -302,7 +302,11 @@ def thread_id_to_camera_id(thread_id):
     main_config = config.get_main()
     threads = main_config.get('thread', '')
 
-    return int(re.search('thread-(\d+).conf', threads[thread_id - 1]).group(1))
+    try:
+        return int(re.search('thread-(\d+).conf', threads[thread_id - 1]).group(1))
+    
+    except IndexError:
+        return None
 
 
 def _disable_initial_motion_detection():
index c43d1966ea8f86b42bc00af0a01602ee55d5c917..a2aacd3e95dce71e0cd9674efd4779b4258edcf9 100644 (file)
@@ -921,7 +921,7 @@ function makeModalDialogTitleBar(options) {
     var titleSpan = $('<span class="modal-title"></span>');
     titleSpan.html(options.title || '');
     if (options.closeButton) {
-        titleSpan.css('margin', '0px 1.5em');
+        titleSpan.css('margin', '0px 2em');
     }
     
     titleBar.append(titleSpan);