public function destroy(Subscription $subscription) { if (is_integer($subscription)) { $subscription = Subscription::find($subscription); } $subscription->delete(); Flash::success('Subscription has been created Deleted!'); return Redirect::back(); }
public function destroy($subscription) { $subscription = Subscription::find($subscription); $subscription->delete(); return response(['data' => true, 'status' => 'success', 'message' => 'successfully deleted']); }