RE: [coldbox:9754] Re: The value returned from the createAppLoader function is not of type coldbox.system.web.loader.AbstractApplicationLoader.

The error occurred in /coldbox/system/web/services/LoaderService.cfc
which extends coldbox.system.web.services.BaseService.

Sorry, that’s not what I meant. I was asking if coldbox.system.web.loader.CFCApplicationLoader extends coldbox.system.web.loader.AbstractApplicationLoader.

That would mean that an instance of CFCApplicationLoader would be able to satisfy the requirement for an instance of AbstractApplicationLoader.

I just looked at the code that XMLApplicationLoader.cfc AND CFCApplicationLoader.cfc BOTH extend the AbstractApplicationLoader.cfc file. The LoaderService is designed to be able to accept an instance of either component. Since they both extend the abstract class, they should both be able to satisfy the requirement.

The reason you are not getting the error is quite possibly because you have the “Disable CFC Type Check” setting enabled. As far as why your host is erroring-- I don’t know. It’s possible your CF install is missing an update. (See Andrew’s question about what version of CF9 you are on)

For what it’s worth, you should request that your host enable the “Disable CFC Type Check” setting. I leave type checking on in development to help validate stuff as I code. On production, it’s commonplace to disable the type checking for performance (and since you should already know that the code works by then).

Thanks!

~Brad

I am not convinced this is the case Brad, I have that disabled here and it works fine here for me as well.

If you read the typeCFC check it is for arguments only, not return types. In fact I went looking and can’t find any setting what so ever that is related to return types.

My guess is that he hasn’t reinitialised the application when moving the changes to production.

Regards,

Andrew Scott

http://www.andyscott.id.au/

"Disable CFC Type Check" setting is not enabled in my local
development environment where it does not generate an error-so it
isn't likely to be the issue here.
So I guess changing the returntype it to "component" or "any" should
fix the issue.

Thanks for the help!

Marc