I ended up figuring it out thanks to that link and insight from Tom Looman. I needed to use the rotation from the camera not the muzzlesocket of the weapon:
//EyeRotation is my camera’s rotation, Hit is the output from LineTraceBySingleChannel, StartingLocation is the location of the weapon’s muzzlesocket
float Orientation = FVector::DotProduct(EyeRotation.Vector(), (Hit.ImpactPoint - StartingLocation).GetSafeNormal());
UE_LOG(LogTemp, Warning, TEXT(“Orientation is: %f”), Orientation);
if (Orientation > 0.0f)
{
StartingRotation = UKismetMathLibrary::FindLookAtRotation(StartingLocation, TraceEnd);
}
//else leave StartingRotation to be set as FRotator StartingRotation = MyOwner->GetController()->GetControlRotation();