fixing rest consolidation bug