change picture before switch bug fix