diff --git a/alib2algo/src/arbology/exact/ExactPatternMatchingAutomaton.h b/alib2algo/src/arbology/exact/ExactPatternMatchingAutomaton.h
index a5087a8ec03110fec6592c6104b193e2bd30a6e3..6b098de11b09050c04c7948bcd43fffc89daedee 100644
--- a/alib2algo/src/arbology/exact/ExactPatternMatchingAutomaton.h
+++ b/alib2algo/src/arbology/exact/ExactPatternMatchingAutomaton.h
@@ -216,7 +216,7 @@ automaton::NFTA < SymbolType, unsigned > ExactPatternMatchingAutomaton::construc
 }
 
 template < class SymbolType >
-unsigned constructRecursivePattern ( const ext::tree < common::ranked_symbol < SymbolType > > & node, automaton::NFTA < SymbolType, unsigned > & res, const common::ranked_symbol < SymbolType > & subtreeWildcard, unsigned loopState, unsigned & nextState ) {
+unsigned constructRecursivePattern ( const ext::tree < common::ranked_symbol < SymbolType > > & node, automaton::NFTA < SymbolType, unsigned > & res, const common::ranked_symbol < SymbolType > & subtreeWildcard, unsigned & nextState ) {
 	if ( node.getData ( ) == subtreeWildcard ) {
 		unsigned state = nextState++;
 		res.addState ( state );
@@ -226,7 +226,7 @@ unsigned constructRecursivePattern ( const ext::tree < common::ranked_symbol < S
 			states.reserve ( ( size_t ) symbol.getRank ( ) );
 
 			for ( unsigned i = 0; i < ( unsigned ) symbol.getRank ( ); i++ )
-				states.push_back ( loopState );
+				states.push_back ( state );
 
 			res.addTransition ( symbol, states, state );
 		}
@@ -237,7 +237,7 @@ unsigned constructRecursivePattern ( const ext::tree < common::ranked_symbol < S
 		states.reserve ( ( size_t ) node.getData ( ).getRank ( ) );
 
 		for ( const ext::tree < common::ranked_symbol < SymbolType > > & child : node.getChildren ( ) )
-			states.push_back ( constructRecursivePattern ( child, res, subtreeWildcard, loopState, nextState ) );
+			states.push_back ( constructRecursivePattern ( child, res, subtreeWildcard, nextState ) );
 
 		unsigned state = nextState++;
 		res.addState ( state );
@@ -257,20 +257,7 @@ automaton::NFTA < SymbolType, unsigned > ExactPatternMatchingAutomaton::construc
 
 	unsigned nextState = 0;
 
-	unsigned loopState = nextState++;
-	res.addState ( loopState );
-
-	for ( const common::ranked_symbol < SymbolType > & symbol : res.getInputAlphabet ( ) ) {
-		ext::vector < unsigned > states;
-		states.reserve ( ( size_t ) symbol.getRank ( ) );
-
-		for ( unsigned i = 0; i < ( unsigned ) symbol.getRank ( ); i++ )
-			states.push_back ( loopState );
-
-		res.addTransition ( symbol, states, loopState );
-	}
-
-	res.addFinalState ( constructRecursivePattern ( pattern.getContent ( ), res, pattern.getSubtreeWildcard ( ), loopState, nextState ) );
+	res.addFinalState ( constructRecursivePattern ( pattern.getContent ( ), res, pattern.getSubtreeWildcard ( ), nextState ) );
 	return res;
 }