Check waiting status when updating module status

Now when looking for the module to update its status, it is looked for
by name and waiting status to solve the issue with the duplicates.

Closes #15