F-2024-0006·dead-code

Unused private variable _pausedFlags in SelectivePausableUpgradable contract

Fixedbridgenearrainbow-bridgegithub.com/Near-One/rainbow-token-connector
TL;DR

SelectivePausableUpgradable defines a private _pausedFlags that is never used; developers may confuse it with SelectivePausableStorage._pausedFlags.

Severity
INFO
Impact
LOW
Likelihood
LOW
Method
MManual review
CAT.
Complexity
LOW
Exploitability
LOW
02Section · Description

Description

The SelectivePausableUpgradable contract utilizes unstructured storage to avoid storage collision by storing the SelectivePausableStorage struct in a specific storage slot determined by keccak256(abi.encode(uint256(keccak256("aurora.SelectivePausable")) - 1)) & ~bytes32(uint256(0xff)). However, the contract also defines a private variable _pausedFlags that is not used anywhere in the code. This unused variable can cause confusion for developers in future development, as it might be mistaken for the SelectivePausableStorage._pausedFlags, leading to potential errors.

03Section · Impact

Impact

The presence of an unused private variable _pausedFlags can cause confusion during future development. Developers might mistakenly use this variable instead of SelectivePausableStorage._pausedFlags, leading to potential errors or unintended behavior in the contract's functionality.

04Section · Recommendation

Recommendation

Remove the unused private variable _pausedFlags from the SelectivePausableUpgradable contract to eliminate any confusion and ensure clarity in the code. This will prevent future developers from mistakenly using the wrong variable.

05Section · Resolution

Resolution

Resolved.

Status
Fixed
F-2024-0006

oog
zealynx

Smart Contract Security Digest

Monthly exploit breakdowns, audit checklists, and DeFi security research — straight to your inbox

© 2026 Zealynx