Minor bug fix
Merge with Rahul's change: clean up