Support the ongoing development of Laravel.io →

Roy Freij

Joined 27 Jun 2019

Statistics

Threads 0
Replies 1
Solutions 0
Articles 0

rfreij has not posted any threads yet

replied 3 years ago

Is there a sexyer way to write this code? (Laravel/Scout)

Hi Lucas. You should be able to use the conditional clause on the builder to achieve this. Your use-...

lucasjose501, mrkalmdn liked this reply

2 Likes

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.