manishkatyan / strapi-stripe

Stripe Plugin for Strapi CMS
66 stars 33 forks source link

fix issue #31 (undefined extensions path) #33

Closed RanderGabriel closed 2 years ago

RanderGabriel commented 2 years ago

When i try to install the plugin there is an error (The "path" argument must be of type string. Received undefined) threw on the register file. It was reported on issue #31 .

This pull request fixes that issue by getting the path from strapi.dirs.dist.extensions if strapi.dirs.extensions is undefined.

Idk if the verification is needed, but as i cannot test this change in other environments (i'm running windows 11) i kept the previous version as a fallback