correct offline issue -- JS is dynamically typed