This may be as intended. It was in Moo2. If you are capped for amount of ships and then go over you are charge a fee. If you then refit a ship, you drop under the cap for the duration of the refitting. I happened to go over, but intended to scrap a few ships, when I upgrade a battleship and saw I was under the cap. Still going to scrap the ships as I need to make new design. Probably not worth changing as it is not a long term issue and I suspect many Moo2 players use it from time to time.
Yes, I was aware of that situation. We can say that while not ideal it's working as intended. Thanks.