mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-03-06 12:31:33 +01:00
Merge pull request #5661 from NodeBB/utils-rtrim
Deprecate non-standard `String.prototype.rtrim`
This commit is contained in:
@@ -171,4 +171,11 @@ describe('Utility Methods', function () {
|
||||
}
|
||||
done();
|
||||
});
|
||||
|
||||
it('`utils.rtrim` should remove trailing space', function (done) {
|
||||
assert.strictEqual(utils.rtrim(' thing '), ' thing');
|
||||
assert.strictEqual(utils.rtrim('\tthing\t\t'), '\tthing');
|
||||
assert.strictEqual(utils.rtrim('\t thing \t'), '\t thing');
|
||||
done();
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user