A lawsuit brought by two men injured in a 2018 shooting at a western Pennsylvania magisterial district court office has been dismissed.