Shorten loadPlugins function in example