GitHub

Bugs Fixed DEBUG

Ver: 4.0.3 - Build: 77a32b0

 

Bugs Fixed in App and System

file: ./system/Cache/Handlers/FileHandlers.php
      public function __construct($config)
      {
        $path = ! empty($config->storePath) ? $config->storePath : WRITEPATH . 'cache';
        if (! is_really_writable($path))
        {

      # John's PROPOSAL START =======================================
        $aTmp = [
         'Unable to log Errors and/or warnings', 
         'Please set ../writable folder permissions to 0777',
         '../writable folder permissions not set to 0777',
         'Please consult manual regarding ../writable folder',
         '\t\tWhoops! \n\nWe seem to have hit a snag. \n\n\tPlease try again later...\n\n',
         'Better suggestions welcome \n\n\t\t :)\n\n',
         'Shit happens :(',
         ];
        $tmp = $aTmp[mt_rand(0, count($aTmp)-1 )];
        $tmp = $tmp 
             . '\n\n'
             . 'https://forum.codeigniter.com/thread-75857.html'
             ;

        ?>
          <script> alert("<?= $tmp ?>"); </script>
        <?php
        # throw CacheException::forUnableToWrite($path);
      # John's PROPOSAL FINISH =======================================

    }

    $this->prefix = $config->prefix ?: '';
    $this->path   = rtrim($path, '/') . '/';
  }//endfunc

file: app-strict/Views/html/errors/error_exception.php
# JOHN MODIFIED
# GLOBAL REPLACED TO ENSURE ONLY STRING
  # ! is_array($value) && ! is_object($value)
  is_string($value) 
file: system/Database/Query.php
public function getStartTime(bool $returnRaw = false, int $decimals = 6): string
{
  if ($returnRaw)
  {
    # JOHN MODIFIED
    # return $this->startTime;
    return number_format($this->startTime, $decimals);
  }

  return number_format($this->startTime, $decimals);
}
file: system/Database/MySQLi/Connection.php
public function connect(bool $persistent = false)
{
// Do we have a socket path?
if ($this->hostname[0] === '/')
{
  $hostname = null;
  $port     = null;
  $socket   = $this->hostname;
}
else
{
  $hostname = ($persistent === true) ? 'p:' . $this->hostname : $this->hostname;
  $port     = empty($this->port) ? null : $this->port;
  # JOHN MODIFIED
  # $socket = null;
  $socket   = '';
}