When refresh all, TypeError: string indices must be integers