Skip to content

Commit

Permalink
don't mint if wearer isn't changing
Browse files Browse the repository at this point in the history
  • Loading branch information
Da-Colon committed Nov 15, 2024
1 parent 3b7a1af commit 428d175
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion contracts/autonomous-admin/DecentAutonomousAdminV1.sol
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,9 @@ contract DecentAutonomousAdminV1 is
// This will burn the hat since wearer is no longer eligible
args.hatsProtocol.checkHatWearerStatus(args.hatId, args.currentWearer);
// This will mint the hat to the nominated wearer
args.hatsProtocol.mintHat(args.hatId, args.nominatedWearer);
if (args.nominatedWearer != args.currentWearer) {
args.hatsProtocol.mintHat(args.hatId, args.nominatedWearer);
}
}

function supportsInterface(
Expand Down

0 comments on commit 428d175

Please sign in to comment.