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 $table = new PhabricatorUser(); $conn_w = $table->establishConnection('w'); foreac..

Decoded Output download

<?php

$table = new PhabricatorUser();
$conn_w = $table->establishConnection('w');

foreach (new LiskMigrationIterator($table) as $user) {
  $username = $user->getUsername();
  echo pht('Migrating %s...', $username)."
";
  if ($user->getIsEmailVerified()) {
    // Email already verified.
    continue;
  }

  $primary = $user->loadPrimaryEmail();
  if (!$primary) {
    // No primary email.
    continue;
  }

  if (!$primary->getIsVerified()) {
    // Primary email not verified.
    continue;
  }

  // Primary email is verified, so mark the account as verified.
  queryfx(
    $conn_w,
    'UPDATE %T SET isEmailVerified = 1 WHERE id = %d',
    $table->getTableName(),
    $user->getID());
}

echo pht('Done.')."
";
 ?>

Did this file decode correctly?

Original Code

<?php

$table = new PhabricatorUser();
$conn_w = $table->establishConnection('w');

foreach (new LiskMigrationIterator($table) as $user) {
  $username = $user->getUsername();
  echo pht('Migrating %s...', $username)."\n";
  if ($user->getIsEmailVerified()) {
    // Email already verified.
    continue;
  }

  $primary = $user->loadPrimaryEmail();
  if (!$primary) {
    // No primary email.
    continue;
  }

  if (!$primary->getIsVerified()) {
    // Primary email not verified.
    continue;
  }

  // Primary email is verified, so mark the account as verified.
  queryfx(
    $conn_w,
    'UPDATE %T SET isEmailVerified = 1 WHERE id = %d',
    $table->getTableName(),
    $user->getID());
}

echo pht('Done.')."\n";

Function Calls

None

Variables

None

Stats

MD5 4e007133ed39f043d970c9c6801ee3b6
Eval Count 0
Decode Time 96 ms