Author Topic: A bug Discovered in SMF Shop 2.1 build 9  (Read 4500 times)

Offline navjotjsingh

A bug Discovered in SMF Shop 2.1 build 9
« on: June 09, 2006, 11:44:20 pm »
When I make a custom item especially a file download and want it to be that it should not get deleted from one's inventory after use because user may not be able to download correctly in the first use.

So for this I always uncheck this option before adding this item Delete item from inventory after use

But still on using that item once it gets deleted. It seems a flaw that before deleting it from inventory it does not even check that whether it was marked for deletion or not. Please can somebody suggest a fix for it as I am not much into PHP.

Also please include that option to be edited from Edit Item menu also so even after making a file download I can make sure that i have unchecked the box afterwards also.

Offline Daniel15

Re: A bug Discovered in SMF Shop 2.1 build 9
« Reply #1 on: June 10, 2006, 02:21:45 pm »
Oh no! There's a bug in the file!
Open Sources/shop/items/filedownload.php
Find:
Code: [Select]
if (isset($item_info[3]) && $item_info[3] = "on") {Replace with:
Code: [Select]
if (isset($item_info[3]) && $item_info[3] == "on") { (notice the extra '=')

It should now be fixed. Sorry about that!
« Last Edit: June 10, 2006, 02:26:50 pm by daniel15 »

Offline navjotjsingh

Re: A bug Discovered in SMF Shop 2.1 build 9
« Reply #2 on: June 18, 2006, 05:21:28 am »
Thanks a ton for fixing the bug...Hope you solve this bug in the next version automatically...Now its working.

Offline navjotjsingh

Re: A bug Discovered in SMF Shop 2.1 build 9
« Reply #3 on: June 18, 2006, 05:24:40 am »
Files can be used while they are in trade center and as soon you use them they get removed from trade center also. Another bug....sorry for double posting.

Offline Daniel15

Re: A bug Discovered in SMF Shop 2.1 build 9
« Reply #4 on: June 23, 2006, 10:37:35 pm »
No problem... I'll try to have a look at that when I'm not busy ;)