Dictionary.com
Thesaurus.com

had been righting

  • past perfect progressive
    of right.
    right
    adjective
    in accordance with what is good, proper, or just.