4-bit Self-correcting Johnson Counter on D flip-flops
A correctly-operating 4-bit Johnson counter loops through 8 legal states. But any collection of four FFs has a total of 24 = 16 possible states. Therefore, there are also 8 "illegal" states.

Since you know the circuit for a Johnson counter, you can draw the complete state transition diagram (or table) for all 16 states. The illegal states will form one or more loops, too. Some of the illegal states can be converted to legal states by flipping only the first bit.

Find them, and implement the logic to do this. Then verify that ALL of the illegal states eventually get to a legal state.