Correctly generate select related on Django >= 1.6