What should I check before purchasing a second-hand smartphone?