kilbot / WooCommerce-POS

:bangbang: All development now at https://github.com/wcpos.
http://wcpos.com
GNU General Public License v3.0
353 stars 125 forks source link

Cannot activate plugin if similar plugin active, class name WC_POS_Admin_Notices collision #138

Closed gnanet closed 8 years ago

gnanet commented 8 years ago

If https://codecanyon.net/item/woocommerce-point-of-sale-pos/7869665 is already active, your plugin cannot be activated, it fails with a "cannot redeclare class WC_POS_Admin_Notices" like error.

I know that activating two plugins with same purpose is not a good idea, i only stumbled upon a site where somehow both plugins were activated, but their setup page was not loading, and for both the setup-menuitems url pointed to the same location.

gnanet commented 8 years ago

A quick search revealed this: https://github.com/search?q=WC_POS_Admin_Notices&ref=searchresults&type=Code&utf8=%E2%9C%93

there are results for both plugins

kilbot commented 8 years ago

Hi @gnanet.

This problem is due to two things:

  1. The code canyon plugin has copied chunks of code from my open source project
  2. In some cases they have prefixed their classes with WC_POS, despite this being the namespace I have used since I released my plugin several months before they released theirs.

Please see this conversation for my request that they address these issues.

In the next version of WooCommerce POS I am moving to a different namespaced structure so this problem should be averted ... unless of course they copy my new code ðŸ˜