We should use a static variable so that we only have to query the hotkey database once, rather than once for each node we're trying to add links to.

Here is a patch. This patch is against 2.2, with my previous patch applied to it #1086696: Hooks for modules to define hotkeys. If you'd rather have a clean patch against 2.2, I can make one of those, too.

CommentFileSizeAuthor
hotkey_use_static.diff4.91 KBgalaxor

Comments

galaxor’s picture

Status: Active » Needs review
smokris’s picture

Version: 6.x-2.2 » 6.x-2.3
Assigned: Unassigned » smokris
Status: Needs review » Fixed

Thanks. Applied. Present in 6.x-2.4.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.