mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-04-20 15:36:16 -04:00
fixed merge conflicts
This commit is contained in:
commit
b300dc1d2c
12 changed files with 231 additions and 30 deletions
|
@ -34,7 +34,7 @@ var tempDirectory = "/tmp";
|
|||
//tempDirectory changes if the operating system is windows
|
||||
if(os.type().indexOf("Windows") > -1)
|
||||
{
|
||||
tempDirectory = "c:\\Temp";
|
||||
tempDirectory = process.env.TEMP;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -35,7 +35,7 @@ var tempDirectory = "/tmp/";
|
|||
//tempDirectory changes if the operating system is windows
|
||||
if(os.type().indexOf("Windows") > -1)
|
||||
{
|
||||
tempDirectory = "c:\\Temp\\";
|
||||
tempDirectory = process.env.TEMP;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -166,7 +166,7 @@ async.waterfall([
|
|||
//ensure the padname is valid and the url doesn't end with a /
|
||||
if(!padManager.isValidPadId(req.params.pad) || /\/$/.test(req.url))
|
||||
{
|
||||
next();
|
||||
res.send('Such a padname is forbidden', 404);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -181,7 +181,7 @@ async.waterfall([
|
|||
//ensure the padname is valid and the url doesn't end with a /
|
||||
if(!padManager.isValidPadId(req.params.pad) || /\/$/.test(req.url))
|
||||
{
|
||||
next();
|
||||
res.send('Such a padname is forbidden', 404);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -196,7 +196,7 @@ async.waterfall([
|
|||
//ensure the padname is valid and the url doesn't end with a /
|
||||
if(!padManager.isValidPadId(req.params.pad) || /\/$/.test(req.url))
|
||||
{
|
||||
next();
|
||||
res.send('Such a padname is forbidden', 404);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -225,10 +225,10 @@ async.waterfall([
|
|||
//ensure the padname is valid and the url doesn't end with a /
|
||||
if(!padManager.isValidPadId(req.params.pad) || /\/$/.test(req.url))
|
||||
{
|
||||
next();
|
||||
res.send('Such a padname is forbidden', 404);
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
//if abiword is disabled, skip handling this request
|
||||
if(settings.abiword == null)
|
||||
{
|
||||
|
|
|
@ -24,12 +24,14 @@ var async = require("async");
|
|||
var settings = require("./Settings");
|
||||
var os = require('os');
|
||||
|
||||
var doConvertTask;
|
||||
|
||||
//on windows we have to spawn a process for each convertion, cause the plugin abicommand doesn't exist on this platform
|
||||
if(os.type().indexOf("Windows") > -1)
|
||||
{
|
||||
var stdoutBuffer = "";
|
||||
|
||||
function doConvertTask(task, callback)
|
||||
doConvertTask = function(task, callback)
|
||||
{
|
||||
//span an abiword process to perform the conversion
|
||||
var abiword = spawn(settings.abiword, ["--to=" + task.destFile, task.srcFile]);
|
||||
|
@ -123,7 +125,7 @@ else
|
|||
}
|
||||
}
|
||||
|
||||
function doConvertTask(task, callback)
|
||||
doConvertTask = function(task, callback)
|
||||
{
|
||||
abiword.stdin.write("convert " + task.srcFile + " " + task.destFile + " " + task.type + "\n");
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue