There seems to be a bug when un-doing material creation where instead it would keep creating new materials. tested on Composer 2023.2.3.

upon further testing, this appears to occur when a prim was selected first when the material was assigned then followed up by the undo operation.