ZF-5986: CLONE -Description of useCdn() is wrong, setCdnXxxx() inconsistent with setLocal

Description

Documentation:

"useCdn(): tell the container to utilize the CDN; implicitly enables integration."

Code:


/**
     * Are we using the CDN?
     * 
     * @return void
     */
    public function useCdn()
    {
        return !$this->useLocalPath();
    }

Comments

The original issue reported in ZF-4110 isn't fixed. The documentation still doesn't match the code.

To resolve ZF-4110, the assignee Satoru Yoshida, just changing the doc block return type from void to boolean. However that doesn't address the mismatch between code & documentation.

To be clear, what should useCDN do?

  1. return whether a cdn is being used or not. (Current code implementation)
  2. tell the container to utilize the CDN; implicitly enables integration (What the documentation says)

I think the right answer is No. 1, since it will be consistent with useLocalPath. The documentation needs to be fixed. However, what function should be used to enable loading from the CDN? As of 1.7.6 the only CDN related function that actually enables Dojo is setCdnVersion(). The documentation "setCdnVersion($version = null): set which version of Dojo to utilize from the CDN" doesn't mention that is implicitly enabling dojo.

For consistency should the other setCdnXxx() methods also enable dojo?

verified that the issue still exists in 1.7.6.

Sorry, I have no time now because I have an another trouble.

I cloned this, item, I think I probably should have just created a new issue linked to the original.

There are two issues here: 1. a documentation problem. 2. inconsistencies in the setCdn / setLocal functions.

I think this issue needs knowledge of the Dojo library, but sadly I have not yet. :-(

Bulk change of all issues last updated before 1st January 2010 as "Won't Fix".

Feel free to re-open and provide a patch if you want to fix this issue.