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

Export ToggleOptin results in error #193

Closed
jnccloud opened this issue Oct 7, 2023 · 0 comments · Fixed by #204
Closed

Export ToggleOptin results in error #193

jnccloud opened this issue Oct 7, 2023 · 0 comments · Fixed by #204
Labels
bug Something isn't working need repro This bug report needs confirmation

Comments

@jnccloud
Copy link
Contributor

jnccloud commented Oct 7, 2023

Summary

Export ToggleOptin results in error whenever called.

Reproduction

exports.qbx_core:ToggleOptin(source)

Expected behavior

Metadata value optin (true|false) to be not optin

Actual behavior

An error is returned.

[     script:qbx_core] SCRIPT ERROR: @qbx_core/server/functions.lua:311: attempt to call a nil value (field 'SetPlayerData')
[     script:qbx_core] > ref (@qbx_core/server/functions.lua:311)
[     script:qbx_core] > handler (@qbx_adminmenu/server/main.lua:256)
[script:qbx_adminmenu] SCRIPT ERROR: @qbx_adminmenu/server/main.lua:256: 
[script:qbx_adminmenu]  An error occurred while calling export `ToggleOptin` in resource `qbx_core`:
[script:qbx_adminmenu] 
[script:qbx_adminmenu]  ---

Additional context

optin has traditionally been a broken feature, but with Qbox, I think it would be beneficial for this to work. The first step is to address the issue in the core when triggering the export.

Why keep this export?

Other features rely on this such as:

Scoreboard - Overhead IDs (hiding during spectating or when serving as an onduty admin)
Reports - Disables them from admins when off duty | EDIT: It seems /report was removed. Feature request created at: Qbox-project/qbx_adminmenu#24

Last Updated

Last week

Custom Resources

N/A

Resource Rename

qbx_core

@jnccloud jnccloud added bug Something isn't working need repro This bug report needs confirmation labels Oct 7, 2023
@jnccloud jnccloud changed the title Export ToggleOptin Export ToggleOptin results in error Oct 7, 2023
@D4isDAVID D4isDAVID added this to Issues Oct 7, 2023
@github-project-automation github-project-automation bot moved this to Todo in Issues Oct 7, 2023
@TonybynMp4 TonybynMp4 mentioned this issue Oct 18, 2023
3 tasks
@github-project-automation github-project-automation bot moved this from Todo to Done in Issues Oct 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working need repro This bug report needs confirmation
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

1 participant