mirror of
https://github.com/ONLYOFFICE/server.git
synced 2026-04-07 14:04:35 +08:00
minor errors
This commit is contained in:
committed by
Alexander.Trofimov
parent
6b0f2c56b0
commit
855ca7c9f5
@ -373,7 +373,7 @@ exports.getImageFormat = function(buffer, optExt) {
|
||||
format = constants.AVS_OFFICESTUDIO_FILE_CROSSPLATFORM_SVG;
|
||||
} else {
|
||||
//пробуем по расширению
|
||||
if (optExt.Length > 0 && '.' == optExt[0]) {
|
||||
if (optExt.length > 0 && '.' == optExt[0]) {
|
||||
optExt = optExt.substring(1);
|
||||
}
|
||||
format = exports.getFormatFromString(optExt);
|
||||
|
||||
@ -416,11 +416,12 @@ function* getAllPresence(docId, optZRange, optHVals) {
|
||||
var now = (new Date()).getTime();
|
||||
var expiredKeys;
|
||||
var hvals;
|
||||
var multi;
|
||||
if (optHVals && optZRange) {
|
||||
expiredKeys = optZRange;
|
||||
hvals = optHVals;
|
||||
} else {
|
||||
var multi = redisClient.multi([
|
||||
multi = redisClient.multi([
|
||||
['zrangebyscore', redisKeyPresenceSet + docId, 0, now],
|
||||
['hvals', redisKeyPresenceHash + docId]
|
||||
]);
|
||||
@ -429,7 +430,7 @@ function* getAllPresence(docId, optZRange, optHVals) {
|
||||
hvals = multiRes[1];
|
||||
}
|
||||
if (expiredKeys.length > 0) {
|
||||
var multi = [
|
||||
var commands = [
|
||||
['zremrangebyscore', redisKeyPresenceSet + docId, 0, now]
|
||||
];
|
||||
var expiredKeysMap = {};
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
var pg = require('pg');
|
||||
var configSql = require('config').get('services.CoAuthoring.sql')
|
||||
var configSql = require('config').get('services.CoAuthoring.sql');
|
||||
var connectionString = 'postgres://' + configSql.get('dbUser') + ':' + configSql.get('dbPass') + '@' + configSql.get('dbHost') +
|
||||
(configSql.get('dbPort') ? (':' + configSql.get('dbPort')) : '') + '/' + configSql.get('dbName');
|
||||
|
||||
|
||||
Reference in New Issue
Block a user