Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

append plugin autoPrefix to default prefix #7

Merged
merged 3 commits into from
May 21, 2018

Conversation

GlenTiki
Copy link
Contributor

Using prefix in the default autoload options should apply a prefix for all plugins loaded by this module. This makes it so any modules then loaded by autoload appends the modules autoPrefix to the end of the default autoload prefix.

It also adds a prefixOverride to override the defaultPrefix (and autoPrefix).

I hope this is okay!

Using `prefix` in the default autoload options applies a prefix for all plugins loaded by this module. This makes it so any modules then loaded by autoload appends the modules autoPrefix to the end of the default autoload prefix.

It also adds a prefixOverride to override the defaultPrefix (and autoPrefix).

Tests and docs to follow.
@GlenTiki
Copy link
Contributor Author

Note: this breaks previous behaviour. If both a default prefix option got set and autoPrefix was set, it would default to the default prefix.

@mcollina
Copy link
Member

cc @delvedor

Copy link
Member

@mcollina mcollina left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Member

@delvedor delvedor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@mcollina
Copy link
Member

Thanks @thekemkid!

@mcollina mcollina merged commit 301c599 into fastify:master May 21, 2018
@GlenTiki GlenTiki deleted the patch-1 branch May 21, 2018 08:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants