The MagSafe connector was designed to come apart if you had the MacBook Pro on a desk, and someone tripped on the charging cable. Without it, the MacBook Pro would be launched into the air and land somewhere else, likely damaged, after a brief flight followed by a hard fall to the floor.
If you are extremely confident you will NEVER trip on the cord, you could substitute a USB-C to USB-C charge cable to supply power to your MacBook Pro. But you should make certain your AppleCare policy is up-to-date, as one mistake could Trash your computer. Do you have backups of all your files? Are they current?
TheLittle's suggestion of a lap desk or over-bed desk is a good one, because in addition to reducing the incidence of MagSafe disconnecting, it would also improve cooling. BedClothes can restrict the flow of air around and into the MacBook Pro, and cause overheating.
Conventional wisdom is that you should connect to a power source whenever possible. But in your unusual situation, you may prefer to use the MacBook Pro on its internal batteries, and arrange to connect to power when not using it. This would slow it slightly, and likely consume the battery over the long run, but may be better for your situation. At this writing, battery service for most models is a US$250 proposition.
Of course if the battery already does not last a workday, that idea is a non-starter.