```php
if ($_POST['plan_type'] != '0') {
  if($sector->hasPlanet()) {
    ...
  }
  else {
    ...
  }
}
```