Add support for custom genders (#879)
This commit is contained in:
@@ -68,7 +68,7 @@ class PersonalizationController extends Controller
|
||||
->where('id', $contactFieldTypeId)
|
||||
->firstOrFail();
|
||||
} catch (ModelNotFoundException $e) {
|
||||
return $this->respond([
|
||||
return response()->json([
|
||||
'errors' => [
|
||||
'message' => trans('app.error_unauthorized'),
|
||||
],
|
||||
@@ -94,6 +94,9 @@ class PersonalizationController extends Controller
|
||||
return $contactFieldType;
|
||||
}
|
||||
|
||||
/**
|
||||
* Destroy the contact field type.
|
||||
*/
|
||||
public function destroyContactFieldType(Request $request, $contactFieldTypeId)
|
||||
{
|
||||
try {
|
||||
@@ -101,7 +104,7 @@ class PersonalizationController extends Controller
|
||||
->where('id', $contactFieldTypeId)
|
||||
->firstOrFail();
|
||||
} catch (ModelNotFoundException $e) {
|
||||
return $this->respond([
|
||||
return response()->json([
|
||||
'errors' => [
|
||||
'message' => trans('app.error_unauthorized'),
|
||||
],
|
||||
@@ -109,7 +112,7 @@ class PersonalizationController extends Controller
|
||||
}
|
||||
|
||||
if ($contactFieldType->delible == false) {
|
||||
return $this->respond([
|
||||
return response()->json([
|
||||
'errors' => [
|
||||
'message' => trans('app.error_unauthorized'),
|
||||
],
|
||||
|
||||
Reference in New Issue
Block a user