Changed argument name since Google compiler has an issue with using a reserved name.

git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@8884 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
phamt 2011-02-17 15:17:00 +00:00
parent 76685a9a75
commit 84a547506b

View File

@ -486,10 +486,10 @@ function deleteRow(obj) {
/**
* Count the number of occurrences of a specific character in a string
*
* @param char
* @param c
* Character to count
* @return The number of occurrences
*/
String.prototype.count = function(char) {
return (this.length - this.replace(new RegExp(char, "g"), '').length)/char.length;
String.prototype.count = function(c) {
return (this.length - this.replace(new RegExp(c, 'g'), '').length)/c.length;
};