Skip to content
This repository has been archived by the owner on Jul 28, 2022. It is now read-only.

Commit

Permalink
Return OnUpdate connection
Browse files Browse the repository at this point in the history
  • Loading branch information
Sleitnick committed Apr 20, 2019
1 parent 8e3cfd4 commit aa34a85
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/ServerStorage/Aero/Services/DataService.lua
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
--[[
Server:
PLAYER DATA METHODS:
DataService:Set(player, key, value)
Expand All @@ -15,6 +16,7 @@
DataService:FlushKey(player, key)
DataService:FlushAll()
DataService:FlushAllConcurrent()
GLOBAL DATA METHODS:
DataService:SetGlobal(key, value)
Expand All @@ -23,6 +25,7 @@
DataService:OnUpdateGlobal(key, callback)
DataService:FlushGlobal(key)
DataService:FlushAllGlobal()
CUSTOM DATA METHODS:
DataService:SetCustom(name, scope, key, value)
Expand All @@ -33,8 +36,11 @@
DataService:FlushAllCustom(name, scope, key)
GAME CLOSING CALLBACK:
DataService:BindToClose(callbackFunction)
EVENTS:
DataService.PlayerFailed(player, method, key, errorMessage)
DataService.GlobalFailed(method, key, errorMessage)
DataService.CustomFailed(name, scope, method, key, errorMessage)
Expand Down Expand Up @@ -121,7 +127,7 @@ end


function DataService:OnUpdate(player, key, callback)
self:GetPlayerCache(player):OnUpdate(key, callback)
return self:GetPlayerCache(player):OnUpdate(key, callback)
end


Expand Down

0 comments on commit aa34a85

Please sign in to comment.