[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [nyx/master] color_override config broken if different case



commit ed031ca750be06e4134d58b81448e60020c0cfd8
Author: Damian Johnson <atagar@xxxxxxxxxxxxxx>
Date:   Mon Oct 26 18:06:18 2020 -0700

    color_override config broken if different case
    
    Oops, our code that validates color values normalizes into camel case, but
    doesn't persist that normalization for its usage. As a result Nyx gets into a
    pretty broken state. Caught thanks to Sai.
    
      https://github.com/torproject/nyx/issues/30
---
 nyx/curses.py | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/nyx/curses.py b/nyx/curses.py
index 98b1d11..3c3fa69 100644
--- a/nyx/curses.py
+++ b/nyx/curses.py
@@ -173,6 +173,8 @@ def conf_handler(key, value):
 
     if value not in Color and value != 'None':
       raise ValueError('"%s" isn\'t a valid color' % value)
+
+    return value
   elif key == 'max_line_wrap':
     return max(1, value)
 

_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits