Skip to content

Make success-path event emissions optional #7

@martinjms

Description

@martinjms

Summary

Every SSU deposit/withdraw and gate permit emits an event even on the success path. While useful for indexing and debugging, each event costs gas.

// ssu_extension.move - emits on every successful deposit
emit_event(config, char_game_id, tribe_id, 0, true, 0);

Consider making success-path events configurable (e.g. a flag on the config object) so owners can opt out to save gas in high-traffic scenarios. Deny/error events should always emit for security auditing.

Impact

~10-15% gas reduction per SSU/gate operation when disabled. Low effort.

🤖 Generated with Claude Code

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions