Skip to content

Commit

Permalink
fix linting
Browse files Browse the repository at this point in the history
  • Loading branch information
Manason committed Jun 14, 2024
1 parent 5c862d6 commit 4738453
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions server/commands.lua
Original file line number Diff line number Diff line change
Expand Up @@ -54,14 +54,14 @@ lib.addCommand('admincar', {

local playerData = exports.qbx_core:GetPlayer(source).PlayerData
local vehName, props = lib.callback.await('qbx_admin:client:GetVehicleInfo', source)
local vehicleId = Entity(vehicle).state.vehicleid
if vehicleId then
local existingVehicleId = Entity(vehicle).state.vehicleid
if existingVehicleId then
local response = lib.callback.await('qbx_admin:client:SaveCarDialog', source)

if not response then
return exports.qbx_core:Notify(source, 'Canceled.', 'inform')
end
local success, err = exports.qbx_vehicles:SetPlayerVehicleOwner(vehicleId, playerData.citizenid)
local success, err = exports.qbx_vehicles:SetPlayerVehicleOwner(existingVehicleId, playerData.citizenid)
if not success then error(err) end
else
local vehicleId, err = exports.qbx_vehicles:CreatePlayerVehicle({
Expand Down

0 comments on commit 4738453

Please sign in to comment.