Skip to content

Commit

Permalink
JS implementation: properly test for the property presence
Browse files Browse the repository at this point in the history
  • Loading branch information
Igor Afanasyev committed Dec 22, 2015
1 parent 515bff9 commit 53cb4bd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions js/plurr.js
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@

//
// Choose the plural function based on locale name
//
//
this.locale = function(locale) {
this.plural = pluralEquations[locale];
}; // function locale
Expand All @@ -204,7 +204,7 @@

options = options || {};

var pluralFunc = options.locale != "" ?
var pluralFunc = "locale" in options ?
pluralEquations[options.locale] || pluralEquations.en :
this.plural;

Expand Down

0 comments on commit 53cb4bd

Please sign in to comment.