<commit_before><?php

namespace FlowControl;

use pocketmine\event\block\BlockSpreadEvent;
use pocketmine\event\Listener;
use pocketmine\plugin\PluginBase;
use pocketmine\utils\Config;
use pocketmine\utils\TextFormat;

class Loader extends PluginBase implements Listener{
    
    public function onEnable(){
        $this->saveDefaultConfig();
        $this->getServer()->getPluginManager()->registerEvents($this, $this);
        $this->getLogger()->info(TextFormat::GREEN."FlowControl enabled.");
    }
    
    public function onDisable(){
        $this->getLogger()->info(TextFormat::RED."FlowControl disabled.");
    }
    
    public function onBlockSpread(BlockSpreadEvent $event){
        $block = $event->getBlock();
        if(($block->getId() === 10 || $block->getId() === 11) && $this->getConfig()->get("spread-lava") === false){
            $event->setCancelled();
        }
        if(($block->getId() === 8 || $block->getId() === 9) && $this->getConfig()->get("spread-water") === false){
            $event->setCancelled();
        }
    }
}<commit_msg>Update Loader.php<commit_after><?php

namespace FlowControl;

use pocketmine\event\block\BlockSpreadEvent;
use pocketmine\event\Listener;
use pocketmine\plugin\PluginBase;
use pocketmine\utils\Config;
use pocketmine\utils\TextFormat;

class Loader extends PluginBase implements Listener{
    
    public function onEnable(){
        $this->saveDefaultConfig();
        $this->getServer()->getPluginManager()->registerEvents($this, $this);
        $this->getLogger()->info(TextFormat::GREEN."FlowControl enabled.");
    }
    
    public function onDisable(){
        $this->getLogger()->info(TextFormat::RED."FlowControl disabled.");
    }
    
    public function onBlockSpread(BlockSpreadEvent $event){
        if(($event->getBlock()->getId() === 10 || $event->getBlock()->getId() === 11) && $this->getConfig()->get("spread-lava") === false){
            $event->setCancelled();
        }
        if(($event->getBlock()->getId() === 8 || $event->getBlock()->getId() === 9) && $this->getConfig()->get("spread-water") === false){
            $event->setCancelled();
        }
    }
}
{'fraction_non_alphanumeric': 0.18456531845653185, 'fraction_numerical': 0.005578800557880056, 'mean_word_length': 3.4926931106471817, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 44, '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': '959686', 'n_tokens_mistral': 634, 'n_tokens_neox': 624, 'n_words': 103}