Parcourir la source

Truncate jQuery version, can be long and break display

Gaël Métais il y a 10 ans
Parent
commit
368bf4a6d9
1 fichiers modifiés avec 5 ajouts et 0 suppressions
  1. 5 0
      lib/metadata/policies.js

+ 5 - 0
lib/metadata/policies.js

@@ -312,6 +312,11 @@ var policies = {
                     return null;
                 }
 
+                // Truncate version number (can be long sometimes, no clue why but it can...)
+                if (value.length > 30) {
+                    value = value.substr(0, 28) + '...';
+                }
+
                 return {
                     value: value,
                     score: score,