Made factory a singleton