coding standards
git-svn-id: http://svn.openlayers.org/trunk/openlayers@3804 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -97,9 +97,11 @@ String.indexOf = function(object) {
|
||||
*/
|
||||
String.prototype.camelize = function() {
|
||||
var oStringList = this.split('-');
|
||||
if (oStringList.length == 1) return oStringList[0];
|
||||
if (oStringList.length == 1) {
|
||||
return oStringList[0];
|
||||
}
|
||||
|
||||
var camelizedString = this.indexOf('-') == 0
|
||||
var camelizedString = (this.indexOf('-') == 0)
|
||||
? oStringList[0].charAt(0).toUpperCase() + oStringList[0].substring(1)
|
||||
: oStringList[0];
|
||||
|
||||
|
||||
Reference in New Issue
Block a user