DarkflameServer icon indicating copy to clipboard operation
DarkflameServer copied to clipboard

BUG: Pet entry not removed from database after being released

Open HailStorm32 opened this issue 3 years ago • 1 comments

Make sure you've done the following:

  • [X] I have checked that this issue has not already been reported.

  • [X] I have validated that this issue is not a syntax error of either MySQL or SQLite.

  • [X] I have pulled the latest version of the main branch of DarkflameServer and have confirmed that the issue exists there.

Issue Description

Pet entry in the database is not being removed when a user releases (deletes) their pet. This leads to unnecessary cluttering of the pet_names table.

The pet is removed from the character's xml data, but is not removed from the pet_names table.

Reproduction steps

  1. Tame pet
  2. View the pet_names table (note the entry for the pet just tamed)
  3. Release the pet ingame
  4. Log off and back in
  5. View the pet_names table again (note the entry for the pet just released still there)

Expected Behavior

When a user releases (deletes) their pet, reference to said pet should be removed from the xml data AND the pet_names table

Environment

Running in a Google Cloud instance.

HailStorm32 avatar Dec 29 '21 07:12 HailStorm32

For logging and moderation purposes it may be a good thing that it’s not actually deleted. Possibly could make this a configurable thing?

codeshaunted avatar Jan 31 '22 12:01 codeshaunted