The PasswordStore::s_owner variable is not changed after the initialization inside the constructor, so it is best to set it as immutable to save gas.
If a variable is not changed during the life of the smart contract it is better to set it as immutable because reading it costs much less gas.
More gas is wasted.
Using the command forge test --gas-report, the deployment gas cost results of 225780 without immutable, and 209477 with immutable.
Also the getPassword function consumes max 3320 of gas without immutable, and 1217 with immutable.
manual check
foundry
Set s_owner to immutable.
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.