Soldering close to threaded joint with dope
When I sweat close to wood or another fitting I wet a rag(s) and wrap around the pipe. You want the rag dripping wet. I do this with both water pipes and on hvac with oxy acetylene using silver solder. The wet rag stops the heat but don’t take forever get it hot wet it with solder and get the heat off as soon as it wicks.
Do not move the rag let the joint cool if you move it prior to becoming solid you end up with a cold solder joint.