Corrected few errors in History.js and restoration of queue