The sentence is correct. It emphasizes the priority of one action over the other - that is why two different past tenses are used. Don't be confused by inversion - change of standard word order, it serves to stress the priority. On the whole, it is a typical grammatical pattern, a bit bookish perhaps.