Procházet zdrojové kódy

Fixed code style, simplified text trimming.

Maksymilian Barnaś před 9 roky
rodič
revize
b1c71f7540
1 změnil soubory, kde provedl 2 přidání a 2 odebrání
  1. 2 2
      dev/tasks/dev/utils/inquiries.js

+ 2 - 2
dev/tasks/dev/utils/inquiries.js

@@ -77,10 +77,10 @@ module.exports = {
 };
 
 function appendPeriodIfMissing( text ) {
-	text = text ? String.prototype.trim.call( text ) : '';
+	text = text ? text.trim() : '';
 	const length = text.length;
 
-	if ( length > 0 && text[length - 1] !== '.' ) {
+	if ( length > 0 && text[ length - 1 ] !== '.' ) {
 		text += '.';
 	}