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

Fix #6810: API Get asset by tag, returns the id of a deleted asset instead of existing #6824

Merged
merged 1 commit into from
Mar 14, 2019
Merged

Fix #6810: API Get asset by tag, returns the id of a deleted asset instead of existing #6824

merged 1 commit into from
Mar 14, 2019

Conversation

inietov
Copy link
Collaborator

@inietov inietov commented Mar 14, 2019

The eloquent relationship uses the 'withTrashed()' method, then returns first() encountered. Just erase the withTrashed(), so the soft deleted assets gets ignored.

@inietov inietov requested a review from snipe as a code owner March 14, 2019 03:08
@inietov inietov changed the title Fix API Get asset by tag, returns the id of a deleted asset instead of existing Fix #6810: API Get asset by tag, returns the id of a deleted asset instead of existing Mar 14, 2019
@snipe
Copy link
Owner

snipe commented Mar 14, 2019

@inietov - thanks! Moving forward, can you use the more semantic PR title "Fixed #6810 - APIshowByTag() returns id of deleted asset instead of existing asset". I copy and paste the PR titles into the changelog, so it just makes it easier for me so I don't have to fix them after they're merged for them to make sense in the changelog. Thanks! <3

@snipe snipe merged commit 8c65214 into snipe:develop Mar 14, 2019
@inietov inietov deleted the API-Get-asset-by-tag branch March 14, 2019 03:15
hunterbits added a commit to ballertv/snipe-it that referenced this pull request Apr 2, 2021
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.

2 participants