fix the issue in get gallery