working on resolving strange bugs that seem to stem from history.js