photo sort fix