I'm curios why do you think that. If the codebase is a fruit of his efforts, why shouldn't he do as he wants with it?
I would understand that in cases where a maintainer adds malicious code - but that's not the case here. Author asks for donations, the only negative effect of it is NPM logs getting longer. I think he's well within his moral rights here.