-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathUtilities.lua
More file actions
25 lines (21 loc) · 753 Bytes
/
Copy pathUtilities.lua
File metadata and controls
25 lines (21 loc) · 753 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
------------------------------------------
-- Utilities Module
------------------------------------------
local MageService = MAGESERVICE
------------------------------------------
-- Create the Utils module
------------------------------------------
local Utils = {}
------------------------------------------
-- Utility Functions
------------------------------------------
-- Function to strip realm name from player name
function Utils.StripRealm(playerName)
if not playerName then return nil end
local name = string.match(playerName, "^([^-]+)")
return name or playerName
end
------------------------------------------
-- Register the module in the addon namespace
------------------------------------------
MageService.Utils = Utils