Revert "Set permissions when writing files, log less data"
This reverts commit e2f8951940.
This commit is contained in:
@@ -342,14 +342,14 @@ class WOFileUtils():
|
||||
continue
|
||||
return True
|
||||
|
||||
def textwrite(self, path, content, perm="0o644"):
|
||||
def textwrite(self, path, content):
|
||||
"""
|
||||
Write content into a file
|
||||
"""
|
||||
Log.debug(self, "Writing content in {0}".format(path))
|
||||
try:
|
||||
with os.fdopen(os.open(path, os.O_WRONLY | os.O_CREAT, perm),
|
||||
'w', encoding='utf-8') as final_file:
|
||||
with open("{0}".format(path),
|
||||
encoding='utf-8', mode='w') as final_file:
|
||||
final_file.write('{0}'.format(content))
|
||||
except IOError as e:
|
||||
Log.debug(self, "{0}".format(e))
|
||||
|
||||
Reference in New Issue
Block a user