Care homes in Somerset threatened with closure could be saved