Integration

QB

  • Open qb-core\client\functions.lua file

  • Find the QBCore.Functions.Notify(text, texttype, length, icon) and replace it with the following

function QBCore.Functions.Notify(text, texttype, length)
    texttype = texttype or 'primary'
    length = length or 5000
    exports['savoy_notify']:Notify(texttype, '', text, length)
end

OX

  • Open ox_lib/imports/client.lua file

  • Find the function lib.notify(data) and replace it with the following

function lib.notify(data)
    if type(data) == 'string' then
        data = { description = data }
    end
    
    local notifyType = data.type or 'information'
    local title = data.title or ''
    local description = data.description or ''
    local duration = data.duration or 5000
    
    exports['savoy_notify']:Notify(notifyType, title, description, duration)
end

Last updated