Removed config dependency. TODO - make it actually correct.