More fixes to getSpreadsheet.js