Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,14 @@ var createServer = function (e, opts) {
})
index = e.files.indexOf(index)
}
else {
var sortedFiles = e.files.map(function (el) {
return el.name
}).sort()
index = e.files.findIndex(function (el) {
return el.name === sortedFiles[index]

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

outdent it to pass the travis

})
}

e.files[index].select()
server.index = e.files[index]
Expand Down