Skip to content

Set default upload destination - #1527

Merged
garak merged 10 commits into
dustin10:masterfrom
laurentmuller:master
Aug 27, 2025
Merged

Set default upload destination#1527
garak merged 10 commits into
dustin10:masterfrom
laurentmuller:master

Conversation

@laurentmuller

@laurentmuller laurentmuller commented Aug 13, 2025

Copy link
Copy Markdown
Contributor

Fix #1526

@laurentmuller laurentmuller changed the title First PR for #1526. PR for #1526. Aug 13, 2025
Comment thread docs/usage.md Outdated
@garak garak changed the title PR for #1526. Set default upload destination Aug 14, 2025

@garak garak left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Docs need update

@laurentmuller

Copy link
Copy Markdown
Contributor Author

Hi,
What I need to update ?
Just remove the upload_destination entry in docs/usage.md and explain how the default value is computed?

@garak

garak commented Aug 18, 2025

Copy link
Copy Markdown
Collaborator

Hi, What I need to update ? Just remove the upload_destination entry in docs/usage.md and explain how the default value is computed?

The option can't be removed, it's still valid. The explanation is needed though

@laurentmuller

Copy link
Copy Markdown
Contributor Author

After PR #1529, the ContainerInterface argument is no more present in PropertyMappingResolver class.
It is so impossible to get the 'kernel.project_dir' property.
How to resolve that ?

@garak

garak commented Aug 26, 2025

Copy link
Copy Markdown
Collaborator

With a proper injection

@laurentmuller

Copy link
Copy Markdown
Contributor Author

Done!

Comment thread docs/usage.md Outdated
working mapping.

> [!NOTE]
> If the `upload_destination` parameter is missing, it this concatenated with

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

"it this concatenated" doesn't make sense


protected function fixUploadDestinationConfig(ContainerBuilder $container, array $config): array
{
// mapping with no declared upload_destination use the uri_prefix

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

"use" -> "uses"

@laurentmuller laurentmuller Aug 26, 2025

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

It's the same as comment in fixDbDriverConfig() function. We must also update?

Comment thread src/DependencyInjection/VichUploaderExtension.php
Comment thread docs/usage.md Outdated
working mapping.

> [!NOTE]
> If the `upload_destination` parameter is missing, it this set automatically

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

not much better than before. Don't you have a spell checker?

@garak
garak merged commit d811b78 into dustin10:master Aug 27, 2025
12 checks passed
@laurentmuller

Copy link
Copy Markdown
Contributor Author

Any chance to create a new version ?

@garak

garak commented Aug 29, 2025

Copy link
Copy Markdown
Collaborator

Any chance to create a new version ?

As soon as we solve 1531

@laurentmuller

Copy link
Copy Markdown
Contributor Author

OK. Thank You.

garak pushed a commit to garak/VichUploaderBundle that referenced this pull request Aug 30, 2025
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.

Omit default upload destination.

2 participants