solving domains bug