]> code.ossystems Code Review - openembedded-core.git/commitdiff
wic: pluginbase: use python 3 metaclass syntax
authorEd Bartosh <ed.bartosh@linux.intel.com>
Wed, 15 Feb 2017 17:43:30 +0000 (19:43 +0200)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Sat, 4 Mar 2017 10:42:31 +0000 (10:42 +0000)
Used more readable syntax to specify metaclass for
the base plugin classes.

Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com>
scripts/lib/wic/pluginbase.py

index aea9c02319d112f6afd27bab1938c7829eeb3709..07ccf622f4c91cd560750a77556af9e0254d3ca1 100644 (file)
@@ -32,10 +32,10 @@ class PluginMeta(type):
 
         return class_type
 
-class ImagerPlugin(PluginMeta("Plugin", (), {})):
+class ImagerPlugin(metaclass=PluginMeta):
     wic_plugin_type = "imager"
 
-class SourcePlugin(PluginMeta("Plugin", (), {})):
+class SourcePlugin(metaclass=PluginMeta):
     wic_plugin_type = "source"
     """
     The methods that can be implemented by --source plugins.