Skip to content

Commit

Permalink
Домашнее задание №4 - приведению к стандарту написания кода в github
Browse files Browse the repository at this point in the history
  • Loading branch information
Anton-Shishak committed Apr 8, 2024
1 parent 0bbd5e4 commit f345265
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions balancer/src/public/index.php
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
<?php
require __DIR__ ."/../code/Validator.php";

Check failure on line 2 in balancer/src/public/index.php

View workflow job for this annotation

GitHub Actions / phpcs

Expected at least 1 space after &quot;.&quot;; 0 found

if (isset($_POST['validator'])){
if (!empty($_POST['validator'])){
if (isset($_POST['validator'])) {
if (!empty($_POST['validator'])) {
$result = \Ashishak\Balancer\code\Validator::ValidateText($_POST['validator']);
if ($result === true){
$message = '"'.$_POST['validator'].'" - Строка корректна';
if ($result === true) {
$message = '"'. $_POST['validator'] .'" - Строка корректна';

Check failure on line 8 in balancer/src/public/index.php

View workflow job for this annotation

GitHub Actions / phpcs

Expected at least 1 space before &quot;.&quot;; 0 found

Check failure on line 8 in balancer/src/public/index.php

View workflow job for this annotation

GitHub Actions / phpcs

Expected at least 1 space after &quot;.&quot;; 0 found
http_response_code(200);
} else {
$message = '"'.$_POST['validator'].'" - В строке ошибки';
$message = '"'. $_POST['validator'] .'" - В строке ошибки';

Check failure on line 11 in balancer/src/public/index.php

View workflow job for this annotation

GitHub Actions / phpcs

Expected at least 1 space before &quot;.&quot;; 0 found

Check failure on line 11 in balancer/src/public/index.php

View workflow job for this annotation

GitHub Actions / phpcs

Expected at least 1 space after &quot;.&quot;; 0 found
http_response_code(400);
}
} else {
Expand Down

0 comments on commit f345265

Please sign in to comment.