Find this useful? Enter your email to receive occasional updates for securing PHP code.

Signing you up...

Thank you for signing up!

PHP Decode

<?php namespace Application\Migrations; use Doctrine\DBAL\Schema\Schema; use Wallabag\Do..

Decoded Output download

<?php

namespace Application\Migrations;

use Doctrine\DBAL\Schema\Schema;
use Wallabag\Doctrine\WallabagMigration;

/**
 * Drop theme fields from config table.
 */
final class Version20221123132612 extends WallabagMigration
{
    public function up(Schema $schema): void
    {
        $configTable = $schema->getTable($this->getTable('config'));

        $this->skipIf(!$configTable->hasColumn('theme'), 'It seems that you already played this migration.');

        $configTable->dropColumn('theme');
    }

    public function down(Schema $schema): void
    {
        $configTable = $schema->getTable($this->getTable('config'));

        $this->skipIf($configTable->hasColumn('theme'), 'It seems that you already played this migration.');

        $configTable->addColumn('theme', 'string', [
            'notnull' => true,
        ]);
    }
}
 ?>

Did this file decode correctly?

Original Code

<?php

namespace Application\Migrations;

use Doctrine\DBAL\Schema\Schema;
use Wallabag\Doctrine\WallabagMigration;

/**
 * Drop theme fields from config table.
 */
final class Version20221123132612 extends WallabagMigration
{
    public function up(Schema $schema): void
    {
        $configTable = $schema->getTable($this->getTable('config'));

        $this->skipIf(!$configTable->hasColumn('theme'), 'It seems that you already played this migration.');

        $configTable->dropColumn('theme');
    }

    public function down(Schema $schema): void
    {
        $configTable = $schema->getTable($this->getTable('config'));

        $this->skipIf($configTable->hasColumn('theme'), 'It seems that you already played this migration.');

        $configTable->addColumn('theme', 'string', [
            'notnull' => true,
        ]);
    }
}

Function Calls

None

Variables

None

Stats

MD5 923a37e899a2b6d7929542a24ba97367
Eval Count 0
Decode Time 107 ms