Bug fix in plugin