kalle
03/07/2022, 7:24 PMpboivin
03/07/2022, 7:24 PMLuís Novais
03/07/2022, 10:08 PMkalle
03/07/2022, 10:25 PMHasBlocks on model?Luís Novais
03/07/2022, 10:53 PMLuís Novais
03/07/2022, 11:59 PMLuís Novais
03/08/2022, 12:01 AMuser
03/08/2022, 12:51 AMLuís Novais
03/08/2022, 12:59 AMuser
03/08/2022, 3:07 AMzoi
03/08/2022, 4:02 PMHarings Rob
03/08/2022, 4:39 PMzoi
03/08/2022, 4:40 PMHarings Rob
03/08/2022, 4:40 PMkalle
03/08/2022, 4:59 PMJonathanF
03/08/2022, 5:57 PM->hasImage() to check if a crop existed and if not, the application handled this. Now it throws an Error instead..
What method should I now use to check if a crop exists without throwing an error if it doesn't?kalle
03/08/2022, 7:43 PMpboivin
03/08/2022, 7:56 PMhas_fallback parameter:
function crop_exists($item, $role, $crop)
{
try {
return (bool) $item->image($role, $crop, [], true);
} catch (MediaCropNotFoundException $e) {
return false;
}
}JonathanF
03/08/2022, 8:43 PMpboivin
03/08/2022, 8:46 PMimage() to determine what to with a given model?JonathanF
03/08/2022, 8:46 PMpboivin
03/08/2022, 8:47 PM$mediasParams be an option for you? To see if the model actually defined the crop.JonathanF
03/08/2022, 8:48 PMpboivin
03/08/2022, 8:50 PMHasMedias at this point 😄JonathanF
03/08/2022, 8:52 PMzynth
03/08/2022, 10:33 PMpboivin
03/08/2022, 10:51 PMlaravel new generates out of the box. Are you wondering about the stuff in public/assets/admin/?zynth
03/08/2022, 10:57 PMpboivin
03/08/2022, 11:34 PMHữu Hiếu
03/09/2022, 3:52 AM