more fixes on gallery