fix queries with empty where, which result in generating sql with WHERE 1=1
add support for a sort query option
Merge branch 'list-sort' of https://github.com/mbroadst/epilogue into mbroadst-list-sort and fix tests

Conflicts:
	tests/resource.basic.js
Merge pull request #12 from mbroadst/fix-count-query

fix queries with empty where, which result in generating sql with WHERE 1=1