From 0.14 (2017 Mar) until before 0.19 (2019 Nov), the height of the last block pruned was returned, subject to a bug if there were blocks left unpruned due to sharing files with later blocks.
In #15991, this was “fixed” to the current implementation, introducing a new bug: now, it returns the first unpruned block.
Since the user provides the parameter as a block to include in pruning, it makes more sense to fix the behaviour to match the documentation.
(Additionally, the description of “pruneheight” in getblockchaininfo is fixed to be technically correct)