Index: utils/pub/validator/name.dart |
diff --git a/utils/pub/validator/name.dart b/utils/pub/validator/name.dart |
index cdb08c4d3a5f1676f08fa1aadeec22893f3fbc33..c953d78b282fea79b22b43911b43ee2bbd6f725e 100644 |
--- a/utils/pub/validator/name.dart |
+++ b/utils/pub/validator/name.dart |
@@ -91,12 +91,12 @@ class NameValidator extends Validator { |
var lastMatchEnd = 0; |
for (var match in new RegExp(r"[a-z]([A-Z])").allMatches(source)) { |
builder |
- ..add(source.substring(lastMatchEnd, match.start + 1)) |
- ..add("_") |
- ..add(match.group(1).toLowerCase()); |
+ ..write(source.substring(lastMatchEnd, match.start + 1)) |
+ ..write("_") |
+ ..write(match.group(1).toLowerCase()); |
lastMatchEnd = match.end; |
} |
- builder.add(source.substring(lastMatchEnd)); |
+ builder.write(source.substring(lastMatchEnd)); |
return builder.toString().toLowerCase(); |
} |
} |