mirror of
https://github.com/storytold/vectorcraft.git
synced 2026-11-19 03:08:00 +00:00
find_command searched the list of about 1,000 built-in command specs in order on every call, and a top-level command looks its id up at least three times before it runs. It now finds a built-in in a map from id to spec that is made on the first call. When an id is listed twice, the map keeps the first spec, which is the one the search returned. An id that is not a built-in still goes to the installed plug-ins' commands at the time of the call, so installing or removing a plug-in shows at once and built-ins keep precedence.