fix foundation js bug