bitburner-official / bitburner-src

Bitburner source code.
Other
837 stars 273 forks source link

API: Improve built-in print APIs when printing objects containing Map or Set #1723

Closed catloversg closed 1 month ago

catloversg commented 1 month ago

This PR implements a change mentioned by d0sboots at https://github.com/bitburner-official/bitburner-src/pull/1710#issuecomment-2428142280.

I also made a small behavior change. Current code prints an empty string if the player passes an empty map, but it still prints < Set: > if the player passes an empty Set. I removed the check && [...nativeArg].length, so it will print < Map: > now.