Bugfix: make api consistent for getAllByStates
Bugfix: fixed implementation of PriorityFilter