mirror of
https://github.com/mail-in-a-box/mailinabox.git
synced 2024-11-25 02:47:04 +00:00
in cf7053c124
I allowed editconf.py to insert a setting where we find it already commented-out in order to get an nginx configuration line in the right place, but it wasn't quite right because when run again we would insert the setting a second time
This commit is contained in:
parent
3bab63d4ce
commit
10fbb2b293
@ -74,6 +74,9 @@ while len(input_lines) > 0:
|
|||||||
|
|
||||||
# If this is already the setting, do nothing.
|
# If this is already the setting, do nothing.
|
||||||
if is_comment is None and existing_val == val:
|
if is_comment is None and existing_val == val:
|
||||||
|
# It may be that we've already inserted this setting higher
|
||||||
|
# in the file so check for that first.
|
||||||
|
if i in found: break
|
||||||
buf += line
|
buf += line
|
||||||
found.add(i)
|
found.add(i)
|
||||||
break
|
break
|
||||||
|
Loading…
Reference in New Issue
Block a user