Hi,

While I brower the code of visitors, for the code in visitors_uninstall, I think we can improve it a little bit.

We can actually use db_delete instead of variable_del to delete each items.

This way has been used by boost and flippy. see below link:
http://drupalcode.org/project/boost.git/blob/refs/heads/7.x-1.x:/boost.i...

http://drupalcode.org/project/flippy.git/blob/refs/heads/7.x-1.x:/flippy...

I think this is a better way to manage the code.

I will patch for this. thanks for your attention.

Comments

zterry95’s picture

Here is the patch.
Hope it can help.

If you are going to use this patch, pls don't forget to add
--author="zterry95 <zterry95@1952394.no-reply.drupal.org>"
as parameter when you commit it. Thank you:)

gashev’s picture

Issue summary: View changes
Status: Active » Closed (won't fix)

Thank you for your patch.

But I don't upload this patch. This patch remove all variables, starting from 'visitors_'. It can remove some variables from another module. It's not right. The current code more strict and remove specific variables of the visitors module.