fixes for redmine 2.5
changes for queries