Ed Sheeran wins plagiarism trial