#6195·lodash

_.invert and _invertBy removes key when _proto_ value

Author: 1Jesper1Created Apr 12, 2026Updated Jul 12, 2026
Labelsbug

=== _.invert === Input: {"userId":"alice","role":"proto","team":"eng"} Expected: {"alice":"userId","proto":"role","eng":"team"} Actual: {"alice":"userId","eng":"team"} Has proto key? false BUG: The role entry is silently dropped!

=== _.invertBy === Input: {"a":"group1","b":"proto","c":"group1"} Expected: {"group1":["a","c"],"proto":["b"]} Actual: {"group1":["a","c"]} Has proto key? false BUG: The proto group is silently dropped!