allow passing newLineCharacter ot getValue
This commit is contained in:
parent
27264bb9d9
commit
d619e4e746
1 changed files with 4 additions and 4 deletions
|
|
@ -83,8 +83,8 @@ var Document = function(textOrLines) {
|
||||||
/**
|
/**
|
||||||
* Returns all the lines in the document as a single string, joined by the new line character.
|
* Returns all the lines in the document as a single string, joined by the new line character.
|
||||||
**/
|
**/
|
||||||
this.getValue = function(newLineCharacter) {
|
this.getValue = function() {
|
||||||
return this.getAllLines().join(newLineCharacter || this.getNewLineCharacter());
|
return this.getAllLines().join(this.getNewLineCharacter());
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -213,8 +213,8 @@ var Document = function(textOrLines) {
|
||||||
*
|
*
|
||||||
* @returns {String}
|
* @returns {String}
|
||||||
**/
|
**/
|
||||||
this.getTextRange = function(range, newLineCharacter) {
|
this.getTextRange = function(range) {
|
||||||
return this.getLinesForRange(range).join(newLineCharacter || this.getNewLineCharacter());
|
return this.getLinesForRange(range).join(this.getNewLineCharacter());
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue