fixing priority sort after load