Fragmentation is not the issue. You probably managed to get a benefit from a background activity that all modern HDD's do. It involves finding and replacing weak Sectors on the HDD with a spare stock of good Sectors that the HDD knows about. This process is invisible to Windows, so it cannot use it. However, completely wiping a HDD will force the HDD to inspect ALL the Sectors of the HDD and replace all that are weak or faulty. So after that drastic operation, the HDD will appear to be flawless.
HOWEVER, you should be aware of the potential problem you have with this old unit. As I said all its faulty Sectors have been replaced with good spares. But that means that the HDD's stock of known-good spares is now smaller for any future fix-ups, so eventually this self-repair process will fail. When? Who knows? There is a system on the HDD to check for this and warn you if the stock of spares is getting low. It is part of the SMART system, so if your computer's BIOS is set to check the SMART messages from the HDD, it will show you such a warning when it comes. THEN you know for sure that the HDD is due for quick replacement. The other factor is experience and prediction. Given that this older HDD HAS had some bad Sectors develop that needed replacement, how rapidly will it develop even more in the future? You can't really predict that, except to say it probably will develop problems more rapidly than a brand new HDD. Again, if you pay attention to the SMART messages that will give you some warning. But you should realize that some of these types of errors cannot be fixed, and you WILL lose data in some cases.