qb-core icon indicating copy to clipboard operation
qb-core copied to clipboard

fix: gang/job validation

Open Z3rio opened this issue 1 month ago • 0 comments

Description

It has come to my attention that there are ways for the job data to become unsynced. Such as the isboss value being saved as false, even though it's true in the shared files. (Via no kidding at least 20 tickets of said issue concerning my boss menu and qbcore's isboss state)

I'd imagine this can more specifically be recreated via already having a job, and then said jobs shared data being changed, whilst your "locally" saved player job data wouldn't update.

Therefore this PR aims to introduce validation of said data, to make sure it never ever gets out of sync.

Checklist

  • [x] I have personally loaded this code into an updated qbcore project and checked all of its functionality.
  • [x] My code fits the style guidelines.
  • [x] My PR fits the contribution guidelines.

Z3rio avatar May 26 '24 05:05 Z3rio