mirror of
https://github.com/gryf/wicd.git
synced 2026-03-15 14:13:42 +01:00
Fix some minor formatting issues
Don't save wired profiles that have only whitespace in their names.
This commit is contained in:
@@ -1506,8 +1506,10 @@ class WiredDaemon(dbus.service.Object):
|
|||||||
if not self.config.has_option(prof, script):
|
if not self.config.has_option(prof, script):
|
||||||
self.config.set(prof, script, None)
|
self.config.set(prof, script, None)
|
||||||
|
|
||||||
if profilename == "":
|
profilename = profilename.strip()
|
||||||
|
if not profilename:
|
||||||
self.config.write()
|
self.config.write()
|
||||||
|
print "Warning: Bad wired profile name given, ignoring."
|
||||||
return "500: Bad Profile name"
|
return "500: Bad Profile name"
|
||||||
if self.debug_mode:
|
if self.debug_mode:
|
||||||
print "saving wired profile %s" % profilename
|
print "saving wired profile %s" % profilename
|
||||||
|
|||||||
Reference in New Issue
Block a user