Fix readQueue and pendingChanges