mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-11-28 14:03:48 +03:00
🐛 Fixed escaping <
in reading time helper (#9508)
no issue Using the < character raw isn't w3 complaint
This commit is contained in:
parent
9030161db9
commit
63aeebb144
@ -28,7 +28,7 @@ module.exports = function reading_time(options) {// eslint-disable-line camelcas
|
||||
readingTimeSeconds,
|
||||
readingTimeMinutes,
|
||||
readingTime,
|
||||
seconds = _.isString(options.hash.seconds) ? options.hash.seconds : '< 1 min read',
|
||||
seconds = _.isString(options.hash.seconds) ? options.hash.seconds : '< 1 min read',
|
||||
minute = _.isString(options.hash.minute) ? options.hash.minute : '1 min read',
|
||||
minutes = _.isString(options.hash.minutes) ? options.hash.minutes : '% min read';
|
||||
|
||||
|
@ -29,7 +29,7 @@ describe('{{reading_time}} helper', function () {
|
||||
},
|
||||
result = helpers.reading_time.call(data);
|
||||
|
||||
String(result).should.equal('< 1 min read');
|
||||
String(result).should.equal('< 1 min read');
|
||||
});
|
||||
|
||||
it('[success] renders reading time for more than one minute text correctly', function () {
|
||||
|
Loading…
Reference in New Issue
Block a user