Quantcast

Added optdeps to libdebug to use enhanced print

Alar of Daggerspine [06-20-15 - 15:19]
Added optdeps to libdebug to use enhanced print

Signed-off-by: Alar of Daggerspine <alar@aspide.it>
Filename
GarrisonCommander-Broker/GarrisonCommander-Broker.toc
GarrisonCommander-Broker/ldb.lua
diff --git a/GarrisonCommander-Broker/GarrisonCommander-Broker.toc b/GarrisonCommander-Broker/GarrisonCommander-Broker.toc
index 6412ce1..e4ef0f2 100644
--- a/GarrisonCommander-Broker/GarrisonCommander-Broker.toc
+++ b/GarrisonCommander-Broker/GarrisonCommander-Broker.toc
@@ -9,7 +9,7 @@
 ## X-Revision: @project-abbreviated-hash@
 ## eMail: alar@aspide.it
 ## URL: http://wow.aspide.it
-## OptionalDeps: Titan, Bazooka, ChocolateBar , FuBar , LibDataBroker-1.1
+## OptionalDeps: Titan, Bazooka, ChocolateBar , FuBar , LibDataBroker-1.1, LibDebug
 ## DefaultState: Enabled
 ## SavedVariables: dbGACB
 ## X-ID: GACB
diff --git a/GarrisonCommander-Broker/ldb.lua b/GarrisonCommander-Broker/ldb.lua
index 615e873..94c266c 100644
--- a/GarrisonCommander-Broker/ldb.lua
+++ b/GarrisonCommander-Broker/ldb.lua
@@ -6,10 +6,14 @@ if (not LibStub:GetLibrary("LibDataBroker-1.1",true)) then
 	return
 end
 local pp=print
-if (LibDebug) then LibDebug() end
 --@debug@
 LoadAddOn("Blizzard_DebugTools")
+if LibDebug then LibDebug() end
 --@end-debug@
+--[===[@non-debug@
+setfenv(1,setmetatable({print=function(...) end},{__index=_G}))
+--@end-non-debug@]===]
+print("Garrison-Broker")
 local L=LibStub("AceLocale-3.0"):GetLocale(me,true)
 --local addon=LibStub("AceAddon-3.0"):NewAddon(me,"AceTimer-3.0","AceEvent-3.0","AceConsole-3.0") --#addon
 local addon=LibStub("LibInit"):NewAddon(me,"AceTimer-3.0","AceEvent-3.0","AceConsole-3.0","AceHook-3.0") --#addon
@@ -160,7 +164,7 @@ function addon:CheckDateReset()
 	end
 	self:ScheduleTimer("CheckDateReset",60)
 --@debug@
-	if (today~=oldToday) then
+	if (false and today~=oldToday) then
 		self:Popup(format("o:%s y:%s t:%s r:%s [w:%s m:%s d:%s y:%s] ",oldToday,yesterday,today,reset,CalendarGetDate()))
 		dataobj:Update()
 		farmobj:Update()