mirror of
https://github.com/samba-team/samba.git
synced 2025-05-27 17:05:51 +03:00
enablerecyclebin: Remove unused imports, fix formatting.
This commit is contained in:
parent
c9e3f6ab02
commit
ac28c8216f
@ -2,9 +2,7 @@
|
||||
#
|
||||
# enabled the Recycle Bin optional feature
|
||||
#
|
||||
import base64
|
||||
import optparse
|
||||
import os
|
||||
import sys
|
||||
|
||||
# Find right directory when running from source tree
|
||||
@ -12,7 +10,7 @@ sys.path.insert(0, "bin/python")
|
||||
|
||||
import samba
|
||||
from samba import getopt as options, Ldb
|
||||
from ldb import SCOPE_SUBTREE, SCOPE_BASE, LdbError
|
||||
from ldb import SCOPE_BASE
|
||||
import sys
|
||||
import ldb
|
||||
from samba.auth import system_session
|
||||
@ -48,8 +46,8 @@ configbase=rootDse["configurationNamingContext"]
|
||||
msg = ldb.Message()
|
||||
msg.dn = ldb.Dn(sam_ldb, "")
|
||||
msg["enableOptionalFeature"] = ldb.MessageElement(
|
||||
"CN=Partitions," + str(configbase) + ":766ddcd8-acd0-445e-f3b9-a7f9b6744f2a",
|
||||
ldb.FLAG_MOD_ADD, "enableOptionalFeature")
|
||||
"CN=Partitions," + str(configbase) + ":766ddcd8-acd0-445e-f3b9-a7f9b6744f2a",
|
||||
ldb.FLAG_MOD_ADD, "enableOptionalFeature")
|
||||
res = sam_ldb.modify(msg)
|
||||
|
||||
print "Recycle Bin feature enabled"
|
||||
|
Loading…
x
Reference in New Issue
Block a user