nodeca/charlatan — pull request #5 by suissa (2013-08-07 02:49:44+00:00)
Title: Charlatan.Address.city() get error in pt-br locale

Add city in locale.

Error example:

⇒ mocha moderator.test.js

/Users/jeancarlonascimento/www/projetos/Atrion/dev/megaranto/node_modules/charlatan/lib/charlatan.js:37
if (!data[path[0]] ||
^
TypeError: Cannot read property 'address' of undefined
at getValue (/Users/jeancarlonascimento/www/projetos/Atrion/dev/megaranto/node_modules/charlatan/lib/charlatan.js:37:12)
at Object.exports.translate (/Users/jeancarlonascimento/www/projetos/Atrion/dev/megaranto/node_modules/charlatan/lib/charlatan.js:141:14)
at exports.fetch (/Users/jeancarlonascimento/www/projetos/Atrion/dev/megaranto/node_modules/charlatan/lib/charlatan.js:166:25)
at Object.exports.parse (/Users/jeancarlonascimento/www/projetos/Atrion/dev/megaranto/node_modules/charlatan/lib/charlatan.js:186:13)
at Object.exports.city (/Users/jeancarlonascimento/www/projetos/Atrion/dev/megaranto/node_modules/charlatan/lib/charlatan/address.js:37:20)
at Suite. (/Users/jeancarlonascimento/www/projetos/Atrion/dev/megaranto/test/moderator.test.js:30:36)
at context.describe.context.context (/usr/local/share/npm/lib/node_modules/mocha/lib/interfaces/bdd.js:72:10)
at Object. (/Users/jeancarlonascimento/www/projetos/Atrion/dev/megaranto/test/moderator.test.js:12:1)
at Module._compile (module.js:456:26)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Module.require (module.js:364:17)
at require (module.js:380:17)
at /usr/local/share/npm/lib/node_modules/mocha/lib/mocha.js:152:27
at Array.forEach (native)
at Mocha.loadFiles (/usr/local/share/npm/lib/node_modules/mocha/lib/mocha.js:149:14)
at Mocha.run (/usr/local/share/npm/lib/node_modules/mocha/lib/mocha.js:306:31)
at Object. (/usr/local/share/npm/lib/node_modules/mocha/bin/_mocha:339:7)
at Module._compile (module.js:456:26)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Function.Module.runMain (module.js:497:10)
at startup (node.js:119:16)
at node.js:901:3