Somerset Council has purchased nearly 50 new beds in nursing homes in a bid to get patients discharged from hospital quicker.