```\n      uint256 _pool = balance();\n           if (_pool + _amount > underlyingCap) {\n      revert NYProfitTakingVault__UnderlyingCapReached(underlyingCap);\n            }\n      uint256 _before = underlying.balanceOf(address(this));\n            underlying.safeTransferFrom(msg.sender, address(this), _amount);\n               uint256 _after = underlying.balanceOf(address(this));\n                   _amount = _after - _before;\n```\n