Update crontab.py

This commit is contained in:
dami
2025-09-11 17:26:12 +08:00
parent fb8ca67ac1
commit 143cceeade
+1 -2
View File
@@ -520,6 +520,7 @@ echo "--------------------------------------------------------------------------
if mw.isAppleSystem():
return mw.returnData(True, 'ok')
mw.execShell("mkdir -p /var/spool/cron/crontabs")
file = '/var/spool/cron/crontabs/root'
sys_os = mw.getOs()
@@ -531,8 +532,6 @@ echo "--------------------------------------------------------------------------
elif sys_name.startswith("ubuntu"):
file = '/var/spool/cron/root'
mw.execShell("mkdir -p /var/spool/cron/crontabs")
if not os.path.exists(file):
mw.writeFile(file, '')
content = mw.readFile(file)