Converted to a class based plugin