Describe Pull request
This will prevent the chance of duplicated phone and account numbers, although the chance is very low it's still a possibility as I have experienced this myself and this will resolve that issue. I feel like this should be implemented as these are meant to be unique for each player.
Questions:
- Have you personally loaded this code into an updated qbcore project and checked all it's functionality? Yes
- Does your code fit the style guidelines? Yes
- Does your PR fit the contribution guidelines? Yes
**Describe Pull request**
This will prevent the chance of duplicated phone and account numbers, although the chance is very low it's still a possibility as I have experienced this myself and this will resolve that issue. I feel like this should be implemented as these are meant to be unique for each player.
**Questions (please complete the following information):**
- Have you personally loaded this code into an updated qbcore project and checked all it's functionality? Yes
- Does your code fit the style guidelines? Yes
- Does your PR fit the contribution guidelines? Yes
This issues fixes the possible exploit when removing an item when sending the item slot parameter before you were able to send any amount of an item and it would return as if the remove item worked just fine returning true
When you add a new job, existing players cannot get jobrep for it because the original jobrep metadata is always loaded instead. With this method, existing players can get jobrep for new jobs.
This checks to make sure that jobrep metadata isn't nil so that new players do not get stuck in an infinite loop, and instead creates new jobrep metadata for them.
There may be a better way to do this, but this works.
It causes the index count to be skewed, and in turn causes an error in the thread and it never runs again until restart. Using the pairs alleviated this in a test environment.