Corrected the allocator object and injecting the client.