[REF] stock: small code refactoring
[FIX] stock: fixed wrongly removed line from previous commit