Explorar el Código

Merge pull request #1733 from flyerhzm/append-label-only-when-formatted-defined

append label only when formatted is not undefined
Kevin Brown hace 12 años
padre
commit
0f1372ce72
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      select2.js

+ 1 - 1
select2.js

@@ -905,9 +905,9 @@ the specific language governing permissions and limitations under the Apache Lic
                             formatted=opts.formatResult(result, label, query, self.opts.escapeMarkup);
                             if (formatted!==undefined) {
                                 label.html(formatted);
+                                node.append(label);
                             }
 
-                            node.append(label);
 
                             if (compound) {