Merge with master

old
Javi Velasco 2015-11-28 20:26:11 +01:00
commit 2e0b9fcb5c
2 changed files with 12 additions and 1 deletions

11
.npmignore Normal file
View File

@ -0,0 +1,11 @@
.*rc
.eslintignore
.csscomb.json
.*.yml
.editorconfig
karma.conf.js
server.js
tests.webpack.js
webpack.config.*
docs
spec

View File

@ -113,7 +113,7 @@ class Autocomplete extends React.Component {
source () {
const { source } = this.props;
if (source.hasOwnProperty(length)) {
if (source.hasOwnProperty('length')) {
return new Map(source.map((item) => [item, item]));
} else {
return new Map(Object.keys(source).map((key) => [key, source[key]]));