Fix quality flow and extract a method for retrieving class constructor in a helper