Depends on the condition of your present truck. If NO rust, and basically near pristine (no dents, damage, parts falling off, etc) then spend the money to fix the issues and do some pre-emptive maintenance an parts replacement.
Consider adding a lift pump and filter kit ($745)(such as from Kennedy Diesel), and possibly go ahead and replace the pressure regulator (new Bosch, $185), and relief valve ($195), and you will be good to go for many miles.
I do lots of pre-emptive maintenance on vehicles, so I don't have to worry about problems cropping up at a bad time. If you are one who runs a vehicle into the ground and doesn't fix anything, even minor cosmetic or interior issues, then just go ahead and trade it in. Someone like me will pick it up, do the research, and go through it from front to rear and get all fluids and hoses replaced, do upgrades that improve reliability, and put many miles on it.
Charles