Cacti/plugin_weathermap

The table `weathermap_settings` does not enforce a unique key on the mapid, groupid, and optname columns

TheWitness opened this issue · 1 comments

As reported by @leonardo0014 here: #117 (comment), the table weathermap_settings allows for the same named object to be inserted a multiple of times which should not happen.

This needs to be resolved through the upgrade script and a modified unique key constraint on the columns.

Essentially, we need to:

ALTER TABLE weathermap_settings ADD UNIQUE INDEX mapid_groupid_optname(mapid, groupid, optname);

But the duplicate entries have to be removed first.