Fixed a bunch of bugs with respect to effect duplication in the cache component of the shim layer. Tested on BankAccount 1-3. Works.