Status changes logic enchancements

Status changes logic enchancements
Code cleanup
Status changes logic enchancements

Status changes logic enchancements
Code cleanup
Status logic updated