Merge branch '0.0.10-alpha' of github.com:NuSkooler/enigma-bbs into 0.0.10-alpha
* '0.0.10-alpha' of github.com:NuSkooler/enigma-bbs: Fix real names during message save Improve legacy EOF detector: Must be at least >= size of SAUCE Fix to read direct / full path & 'readSauce' option of art
This commit is contained in:
commit
3436dad57a
|
@ -57,6 +57,9 @@ function sliceAtEOF(data, eofMarker) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if(eof === data.length || eof < 128) {
|
||||||
|
return data;
|
||||||
|
}
|
||||||
return data.slice(0, eof);
|
return data.slice(0, eof);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -144,7 +147,7 @@ function getArt(name, options, cb) {
|
||||||
|
|
||||||
// If an extension is provided, just read the file now
|
// If an extension is provided, just read the file now
|
||||||
if('' !== ext) {
|
if('' !== ext) {
|
||||||
const directPath = paths.join(options.basePath, name);
|
const directPath = paths.isAbsolute(name) ? name : paths.join(options.basePath, name);
|
||||||
return getArtFromPath(directPath, options, cb);
|
return getArtFromPath(directPath, options, cb);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -329,7 +329,7 @@ exports.FullScreenEditorModule = exports.getModule = class FullScreenEditorModul
|
||||||
const msgOpts = {
|
const msgOpts = {
|
||||||
areaTag : this.messageAreaTag,
|
areaTag : this.messageAreaTag,
|
||||||
toUserName : headerValues.to,
|
toUserName : headerValues.to,
|
||||||
fromUserName : this.client.user.username,
|
fromUserName : this.client.user.getProperty(UserProps.RealName) || this.client.user.username,
|
||||||
subject : headerValues.subject,
|
subject : headerValues.subject,
|
||||||
// :TODO: don't hard code 1 here:
|
// :TODO: don't hard code 1 here:
|
||||||
message : this.viewControllers.body.getView(MciViewIds.body.message).getData( { forceLineTerms : this.replyIsAnsi } ),
|
message : this.viewControllers.body.getView(MciViewIds.body.message).getData( { forceLineTerms : this.replyIsAnsi } ),
|
||||||
|
|
|
@ -439,7 +439,7 @@ function getThemeArt(options, cb) {
|
||||||
// :TODO: replace asAnsi stuff with something like retrieveAs = 'ansi' | 'pipe' | ...
|
// :TODO: replace asAnsi stuff with something like retrieveAs = 'ansi' | 'pipe' | ...
|
||||||
// :TODO: Some of these options should only be set if not provided!
|
// :TODO: Some of these options should only be set if not provided!
|
||||||
options.asAnsi = true; // always convert to ANSI
|
options.asAnsi = true; // always convert to ANSI
|
||||||
options.readSauce = true; // read SAUCE, if avail
|
options.readSauce = _.get(options, 'readSauce', true); // read SAUCE, if avail
|
||||||
options.random = _.get(options, 'random', true); // FILENAME<n>.EXT support
|
options.random = _.get(options, 'random', true); // FILENAME<n>.EXT support
|
||||||
|
|
||||||
//
|
//
|
||||||
|
|
Loading…
Reference in New Issue