Added support for passing an Eloquent Collection to sync() when inserting on a many-to-many relationship instead of just an array of IDs
Small change to follow Laravel coding style
Use modelKeys to retrieve relation IDs correctly instead of incorrect ->otherKey
Working on cleaning up some code.