Theis repair is called a "sister joist".
Ideally, they should extend from end to end a and rest on the support that the original joist sets on.
If the original joist is on a hangar, they should install hangars on eah end and space the new joist, "1 joist away" so they have room to screw...