Closed Bug 1806859 Opened 1 year ago Closed 1 year ago

cleanup fallback flag logic

Categories

(Conduit :: moz-phab, task)

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: sheehan, Assigned: sheehan)

Details

Attachments

(1 file)

And add tests for the fallback behaviour.

Right now we set a fallback flag to False, check
a set of conditions for fallback, and if they are
met we set the flag to True and then take some
further action down the line.

Instead, move the fallback checking into a function
and store the result of that function as fallback.
Then check the value of fallback where needed,
avoiding the need to set the flag to False in
the first place.

With the fallback behaviour in a separate function we can
also expand the conditions to make the behaviour more
readable, and add a test.

Status: NEW → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: