I read that we change needn't into didn't have to or didn't need to in reported speech. But in this book I read it doesn't change.