well, maybe just to make it more readable, you can split that long line:
$input = $request->except('image_URL');
$input['image_URL'] = $imageName;
Child::create($input)->parents()->attach(Auth::user()->id);
I don't think you should encrease performance for this single action. It is not used in foreach loop with thousands of iterations or something like this.
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community