Fixed some queries broken by security patch
Merge branch 'master' of github.com:cjford/cc-schedule