coin pooling code fixed