galen / PHP-Instagram-API

PHP 5.3+ wrapper for the Instagram API
337 stars 116 forks source link

Not working with composer #9

Closed splicebison closed 11 years ago

splicebison commented 11 years ago

Fatal error: Class 'Instagram\Instagram' not found...

Composer's autoload_namespaces is generating:

'Instagram' => $vendorDir . '/php-instagram-api/php-instagram-api/Instagram',

and should instead read:

'Instagram' => $vendorDir . '/php-instagram-api/php-instagram-api/.',

oskarhane commented 11 years ago

I got another error when trying to use it with composer, thats probably related.

Fatal error: Class 'Instagram\Core\BaseObjectAbstract' not found in [...]/vendor/php-instagram-api/php-instagram-api/Instagram/Instagram.php on line 27

galen commented 11 years ago

I havent actually used it with composer yet. Ill look into this.

splicebison commented 11 years ago

@orre It's because the base class path is being set incorrectly by composer's generator.

@galen I believe is should be as simple as changing psr-0 autoload information to "Instagram": "."

pdaether commented 11 years ago

I can confirm this issue. The solution from @fishmarket should solve it.