Interplay between weak localization of exciton-polaritons and the optical spin Hall effect