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

added support for "*" parameter in remove methods #6

Closed
wants to merge 1 commit into from
Closed

added support for "*" parameter in remove methods #6

wants to merge 1 commit into from

Conversation

rijk
Copy link
Contributor

@rijk rijk commented Oct 14, 2014

This commit makes it possible to remove all translations of a given key, by passing a * instead of a language identifier. This works in both removeTranslations() and removeLanguage(). Fixes #3.

Examples:

// Remove all translations of the title property 
Collection.removeLanguage(id, ['title'], '*')
Collection.removeTranslations(id, ['*.title'])

// Remove all translations
Collection.removeTranslations(id, ['*'])

This commit makes it possible to remove all translations of a given key, by passing a * instead of a language identifier. This works in both `removeTranslations()` and `removeLanguage()`. Fixes #3.

Examples:

```javascript
// Remove all translations of the title property 
Collection.removeLanguage(id, ['title'], '*')
Collection.removeTranslations(id, ['*.title'])

// Remove all translations
Collection.removeTranslations(id, ['*'])
```
@rijk rijk closed this by deleting the head repository Feb 13, 2023
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.

Invalidate all translations for a given key
1 participant