I\'m getting this error whenever i try to sync an array of inputs to a pivot table:
Illuminate\\Database\\QueryException SQLSTATE[23503]: Foreign key violation: