<commit_before><?php

namespace Octo\Block;

use b8\Config;
use Octo\Block;

class Image extends Block
{
    public static function getInfo()
    {
        $config = Config::getInstance();
        return ['title' => 'Text', 'editor' => true, 'js' => ['/assets/backoffice/js/block/image.js']];
    }

    public function renderNow()
    {
        $this->view->width = 800;
        $this->view->height = 'auto';

        if (isset($this->templateParams['width'])) {
            $this->view->width = $this->templateParams['width'];
        }

        if (isset($this->templateParams['height'])) {
            $this->view->height = $this->templateParams['height'];
        }

        if (isset($this->content['image'])) {
            $this->view->image = $this->content['image'];
            return;
        }
    }
}<commit_msg>Fix for the Image block<commit_after><?php

namespace Octo\Block;

use b8\Config;
use Octo\Block;

class Image extends Block
{
    public static function getInfo()
    {
        return ['title' => 'Text', 'editor' => true, 'js' => ['/assets/backoffice/js/block/image.js']];
    }

    public function renderNow()
    {
        $this->view->width = 800;
        $this->view->height = 'auto';

        if (isset($this->templateParams['width'])) {
            $this->view->width = $this->templateParams['width'];
        }

        if (isset($this->templateParams['height'])) {
            $this->view->height = $this->templateParams['height'];
        }

        if (isset($this->content['image'])) {
            $this->view->image = $this->content['image'];
            return;
        }
    }
}
{'fraction_non_alphanumeric': 0.1871525633106856, 'fraction_numerical': 0.004941321803582459, 'mean_word_length': 2.306122448979592, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 41, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2929715', 'n_tokens_mistral': 494, 'n_tokens_neox': 478, 'n_words': 90}