Fixed controller creation check

When creating controller, and it already exists in the module, old controller will be overwritten with controller stub. This patch fixes it.