DNN-5943 - Fixed minor bug in check State existence before update it