Fixed issues undoing/redoing feature detection.