Add/join association patch - port from rails4.0 version