lib/slack/smart-bot/utils/update_vacations.rb in slack-smart-bot-1.13.2 vs lib/slack/smart-bot/utils/update_vacations.rb in slack-smart-bot-1.14.0
- old
+ new
@@ -8,10 +8,10 @@
user = Thread.current[:user]
vacations_file = File.join(config.path, "vacations", "v_#{user.name}.yaml")
File.open(vacations_file, 'w') {|file|
file.flock(File::LOCK_EX)
- file.write(encrypt(@vacations[user.name].to_yaml))
+ file.write(Utils::Encryption.encrypt(@vacations[user.name].to_yaml, config))
file.flock(File::LOCK_UN)
}
@datetime_vacations_file[vacations_file] = File.mtime(vacations_file)
end
end