protected function run(Request $request, $id) {
$validation = [
- 'password' => 'required|string|min:8',
- 'username' => 'required|string|max:255',
- 'host' => 'required|string|max:255',
+ 'password' => $request->protocol === "hosting" ? 'nullable' : 'required|string|min:8',
+ 'username' => $request->protocol === "hosting" ? 'nullable' : 'required|string|max:255',
+ 'host' => $request->protocol === "hosting" ? 'nullable' : 'required|string|max:255',
'port' => 'nullable|numeric',
];
$validator = Validator::make([