Fixes #1513: Make sure all objects coupled via m2m are saved before assigning them to the m2m-table.
Updated version to 2.4-dev.
Merge branch 'fix_1513'