fixing image galleries