Pulled
Fixed algorithm for associations