1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Not a Bug Can't use namespace on Tools Rebuild

Discussion in 'Resolved Bug Reports' started by Nobita.Kun, Aug 29, 2014.

  1. Nobita.Kun

    Nobita.Kun Well-Known Member

    As title. If you used namespace on Tools Rebuild you can't do.

    Because its hardcode:

    PHP:
    public static function create($class)
        {
            if (
    strpos($class'_') === false)
            {
                
    $class 'XenForo_Deferred_' $class;
            }

            
    $class XenForo_Application::resolveDynamicClass($class);
            
    $object = new $class();
            if (!(
    $object instanceof XenForo_Deferred_Abstract))
            {
                return 
    false;
            }
            return 
    $object;
        }
    I don't find any way to extends that. Hope you can fixed that :)
     
  2. Mike

    Mike XenForo Developer Staff Member

  3. Nobita.Kun

    Nobita.Kun Well-Known Member

    Yep! I know for Controller. I can extends to use that. But with Deferred. You don't provide an way for developer to use that :/
     
  4. Chris D

    Chris D XenForo Developer Staff Member

    Mike has addressed that already in the message he has linked to:

    You'd be better off creating a suggestion but I think Mike has already stated that PHP requirements may change in XF 2.0 so presumably that's where XenForo will catch up with things like namespaces.
     
    Nobita.Kun likes this.
  5. Nobita.Kun

    Nobita.Kun Well-Known Member

    @Chris D Thank You. Hope XenForo 2.0 will full support namespace anywhere ;)
     

Share This Page