concrete/src/Block/BlockType/BlockType.php
public static function getByHandle($btHandle)
    {
        $result = null;
        $btHandle = (string) $btHandle;
        if ($btHandle !== '') {
            $app = Application::getFacadeApplication();
            $em = $app->make(EntityManagerInterface::class);
            $repo = $em->getRepository(BlockTypeEntity::class);
            $result = $repo->findOneBy(['btHandle' => $btHandle]);
            if ($result !== null) {
                $result->loadController();
            }
        }

        return $result;
    }
public static function getByHandle($btHandle)
    {
        $result = null;
        $btHandle = (string) $btHandle;
        if ($btHandle !== '') {
            $app = Application::getFacadeApplication();
            $em = $app->make(EntityManagerInterface::class);
            $repo = $em->getRepository(BlockTypeEntity::class);
            $result = $repo->findOneBy(['btHandle' => $btHandle]);
            if ($result !== null) {
                $result->loadController();
            }
        }

        return $result;
    }
public static function getByHandle ( $ btHandle ) { $ result = null ; $ btHandle = ( string ) $ btHandle ; if ( $ btHandle !== '' ) { $ app = Application :: getFacadeApplication ( ) ; $ em = $ app -> make ( EntityManagerInterface :: class ) ; $ repo = $ em -> getRepository ( BlockTypeEntity :: class ) ; $ result = $ repo -> findOneBy ( [ 'btHandle' => $ btHandle ] ) ; if ( $ result !== null ) { $ result -> loadController ( ) ; } } return $ result ; }
Get a BlockType given its handle.

@param string $btHandle

@return \Concrete\Core\Entity\Block\BlockType\BlockType|null
Get a BlockType given its handle .