Fix adding of picture to gallery