fix gallery photo publishing