seregazhuk/php-pinterest-bot

View on GitHub
examples/multiple_accounts_and_proxy.php

Summary

Maintainability
A
0 mins
Test Coverage

The function getImage() contains an exit expression.
Open

        die();

ExitExpression

Since: 0.2

An exit-expression within regular code is untestable and therefore it should be avoided. Consider to move the exit-expression into some kind of startup script where an error/exception code is returned to the calling environment.

Example

class Foo {
    public function bar($param)  {
        if ($param === 42) {
            exit(23);
        }
    }
}

Source https://phpmd.org/rules/design.html#exitexpression

A file should declare new symbols (classes, functions, constants, etc.) and cause no other side effects, or it should execute logic with side effects, but should not do both. The first symbol is defined on line 36 and the first side effect is on line 3.
Open

<?php

There are no issues that match your filters.

Category
Status