Skip to content

Commit 98bc1d7

Browse files
authored
Merge pull request #11 from winor30/fix-single-owner-plugin-dependency
Refactor SingleOwnerPlugin dependency management
2 parents 450cd64 + f658e9e commit 98bc1d7

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

src/plugins/owner/SingleOwnerPlugin.sol

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@ import {IERC1271} from "@openzeppelin/contracts/interfaces/IERC1271.sol";
66
import {SignatureChecker} from "@openzeppelin/contracts/utils/cryptography/SignatureChecker.sol";
77
import {UserOperation} from "@eth-infinitism/account-abstraction/interfaces/UserOperation.sol";
88

9-
import {UpgradeableModularAccount, UUPSUpgradeable} from "../../account/UpgradeableModularAccount.sol";
9+
import {UUPSUpgradeable} from "@openzeppelin/contracts/proxy/utils/UUPSUpgradeable.sol";
10+
import {IPluginManager} from "../../interfaces/IPluginManager.sol";
1011
import {
1112
ManifestFunction,
1213
ManifestAssociatedFunctionType,
@@ -170,11 +171,11 @@ contract SingleOwnerPlugin is BasePlugin, ISingleOwnerPlugin, IERC1271 {
170171
associatedFunction: ownerUserOpValidationFunction
171172
});
172173
manifest.userOpValidationFunctions[3] = ManifestAssociatedFunction({
173-
executionSelector: UpgradeableModularAccount.installPlugin.selector,
174+
executionSelector: IPluginManager.installPlugin.selector,
174175
associatedFunction: ownerUserOpValidationFunction
175176
});
176177
manifest.userOpValidationFunctions[4] = ManifestAssociatedFunction({
177-
executionSelector: UpgradeableModularAccount.uninstallPlugin.selector,
178+
executionSelector: IPluginManager.uninstallPlugin.selector,
178179
associatedFunction: ownerUserOpValidationFunction
179180
});
180181
manifest.userOpValidationFunctions[5] = ManifestAssociatedFunction({
@@ -214,11 +215,11 @@ contract SingleOwnerPlugin is BasePlugin, ISingleOwnerPlugin, IERC1271 {
214215
associatedFunction: ownerOrSelfRuntimeValidationFunction
215216
});
216217
manifest.runtimeValidationFunctions[4] = ManifestAssociatedFunction({
217-
executionSelector: UpgradeableModularAccount.installPlugin.selector,
218+
executionSelector: IPluginManager.installPlugin.selector,
218219
associatedFunction: ownerOrSelfRuntimeValidationFunction
219220
});
220221
manifest.runtimeValidationFunctions[5] = ManifestAssociatedFunction({
221-
executionSelector: UpgradeableModularAccount.uninstallPlugin.selector,
222+
executionSelector: IPluginManager.uninstallPlugin.selector,
222223
associatedFunction: ownerOrSelfRuntimeValidationFunction
223224
});
224225
manifest.runtimeValidationFunctions[6] = ManifestAssociatedFunction({

0 commit comments

Comments
 (0)