private function editFileName($fileName, $isFromVendor, $siteName){
        if($isFromVendor){
            $pathInfo = explode('/', $fileName);
            for($i = 0; $i <= sizeof($pathInfo); $i++){
                if(!empty($pathInfo[1])){
                    if(str_replace('-', '', ucwords($pathInfo[1], '-')) == $siteName){
                        $fileName = preg_replace('/'.$pathInfo[1].'/', $siteName, $fileName, 1);
                    }
                }
            }
        }
        return $fileName;
    }
private function editFileName($fileName, $isFromVendor, $siteName){
        if($isFromVendor){
            $pathInfo = explode('/', $fileName);
            for($i = 0; $i <= sizeof($pathInfo); $i++){
                if(!empty($pathInfo[1])){
                    if(str_replace('-', '', ucwords($pathInfo[1], '-')) == $siteName){
                        $fileName = preg_replace('/'.$pathInfo[1].'/', $siteName, $fileName, 1);
                    }
                }
            }
        }
        return $fileName;
    }
private function editFileName ( $ fileName , $ isFromVendor , $ siteName ) { if ( $ isFromVendor ) { $ pathInfo = explode ( '/' , $ fileName ) ; for ( $ i = 0 ; $ i <= sizeof ( $ pathInfo ) ; $ i ++ ) { if ( ! empty ( $ pathInfo [ 1 ] ) ) { if ( str_replace ( '-' , '' , ucwords ( $ pathInfo [ 1 ] , '-' ) ) == $ siteName ) { $ fileName = preg_replace ( '/' . $ pathInfo [ 1 ] . '/' , $ siteName , $ fileName , 1 ) ; } } } } return $ fileName ; }
Edit the filename only if site came from vendor
to make the module name camel case
Ex. melis-demo-cms turns into MelisDemoCms

@param $fileName
@param $isFromVendor
@param $siteName
@return string|string[]|null
Edit the filename only if site came from vendor to make the module name camel case Ex . melis - demo - cms turns into MelisDemoCms