// Get the link details $link = Link::active()->where('slug', $slug)->with(['user', 'pixels', 'scripts', 'cta', 'domain'])->first();
// If the domain does not belong to the system
if ($domain != config('settings.link_shorten_domain') ) {
// Make sure the link domain match what is in the db
if ( $link->domain['name'] != $domain )
return redirect()->away( config('app.url') );
}
// Redirect to homepage if the link doesn't exist
if ( ! $link )
return redirect()->away( config('app.url') );
// Check the feature usage ability
// Only check for non admin users
from Newest questions tagged laravel-5 - Stack Overflow https://ift.tt/2ZtIaxI
via IFTTT
Aucun commentaire:
Enregistrer un commentaire