Fixes: #2410 Using __construct for plugin constructor