diff --git a/webapp_admin/webapp_admin.py b/webapp_admin/webapp_admin.py index cf51000..32868f0 100755 --- a/webapp_admin/webapp_admin.py +++ b/webapp_admin/webapp_admin.py @@ -64,7 +64,7 @@ def opt_args(print_help=None): group = OptionGroup(parser, "Signature", "") group.add_option("--backup-signature", dest="backup_signature", action="store_true", help="Backup signature") group.add_option("--restore-signature", dest="restore_signature", action="store", help="Restore signature (need file name)") - group.add_option("--replace-signature", dest="replace_signature", action="store_true", help="Replace existing signature, file layout must be: username_signature-name_signatureid.html") + group.add_option("--replace-signature", dest="replace_signature", action="store", help="Replace existing signature, file layout must be: username_signature-name_signatureid.html") group.add_option("--default-signature", dest="default_signature", action="store_true", help="Set signature as default one") parser.add_option_group(group) @@ -636,7 +636,9 @@ def main(): if options.backup_signature: backup_signature(user, options.location) if options.restore_signature: - restore_signature(user, options.restore_signature, options.replace_signature, options.default_signature) + restore_signature(user, options.restore_signature, False, options.default_signature) + if options.replace_signature: + restore_signature(user, options.replace_signature, True, options.default_signature) # Advanced injection option if options.add_option: