sync of options

This commit is contained in:
azivner
2017-11-02 20:48:02 -04:00
parent 40e27cd6f7
commit c3d776ae13
16 changed files with 142 additions and 59 deletions

View File

@@ -3,6 +3,7 @@
const express = require('express');
const router = express.Router();
const sql = require('../../services/sql');
const options = require('../../services/options');
const utils = require('../../services/utils');
const audit_category = require('../../services/audit_category');
const auth = require('../../services/auth');
@@ -38,7 +39,7 @@ router.put('/:noteId', async (req, res, next) => {
const now = utils.nowTimestamp();
const historySnapshotTimeInterval = parseInt(await sql.getOption('history_snapshot_time_interval'));
const historySnapshotTimeInterval = parseInt(await options.getOption('history_snapshot_time_interval'));
const historyCutoff = now - historySnapshotTimeInterval;