Fix the singleton function injection