Adds check to see if dictionary array passed to sqk_insertOrUpdate is valid

Includes a check to see if dictionary array is valid before attempting to filter nil or empty array.