SwiftUI ViewBuilder can't pass in different views

In Swift/SwiftUI, I’m trying to make a custom view, which takes other views as arguments. However, I’m getting the error Type of expression is ambiguous without more context. I know that this error is usually due to mismatching types. Also, in the implementation below, having 2 Text views causes no error, but using a Text… Read More SwiftUI ViewBuilder can't pass in different views

Cakephp api POST request , saving data without validation

I have created a route with Api prefix $routes->scope(‘/api’, function (RouteBuilder $routes) { $routes->setExtensions([‘json’]); $routes->post( ‘/add-categories’, [‘controller’ => ‘Miles’, ‘action’ => ‘addCategories’,’prefix’=>’Api’] ); } I have created a controller file in directory Controller/Api/MilesController.php I have created a addCategory method like below public function addCategories() { $categoriesTable = $this->fetchTable(‘Categories’); $categoryEnt = $categoriesTable->newEmptyEntity(); if ($this->request->is(‘post’)) { $category… Read More Cakephp api POST request , saving data without validation