Fixed issue with deleting a preference when there are only two and the graph gets deleted.
Merge remote-tracking branch 'origin/master'