Skip to content

Commit

Permalink
Improve the regex (#2)
Browse files Browse the repository at this point in the history
  • Loading branch information
mickstar authored and sindresorhus committed May 28, 2019
1 parent bd33090 commit b360b8e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
'use strict';
module.exports = string => string.replace(/^[\r\n]+/, '').replace(/[\r\n]+$/, '');
module.exports = string => string.replace(/^[\r\n]+|[\r\n]+$/g, '');
module.exports.start = string => string.replace(/^[\r\n]+/, '');
module.exports.end = string => string.replace(/[\r\n]+$/, '');

0 comments on commit b360b8e

Please sign in to comment.