This pull request solves #10 therefore adding support for route groups.
Additions
The GeoGroup class: This class is responsible of defining the route group and applying the geo-constraint on it.
The geomacro method: This is a Router macro method used to define the GeoGroup.
The ControlsAccess trait: Resolves duplicate code, contains the access methods (allow, deny, allowFrom and denyFrom).
The HasCallback trait: Resolves duplicate code, contains the callback-related methods (loadProxies, setCallback and the default callbacks)
Potential Changes
I am concerned about the ControlsAccess and HasCallback traits defining the callback, proxies, strategy and countries properties, i think this might have to be changed to calling methods such as getCallbackProperty as seen in many Laravel traits, so would you please share your opinion concerning this topic?
This pull request solves #10 therefore adding support for route groups.
Additions
GeoGroup
class: This class is responsible of defining the route group and applying thegeo-constraint
on it.geo
macro method: This is a Router macro method used to define theGeoGroup
.ControlsAccess
trait: Resolves duplicate code, contains the access methods (allow
,deny
,allowFrom
anddenyFrom
).HasCallback
trait: Resolves duplicate code, contains the callback-related methods (loadProxies
,setCallback
and the default callbacks)Potential Changes
I am concerned about the
ControlsAccess
andHasCallback
traits defining thecallback
,proxies
,strategy
andcountries
properties, i think this might have to be changed to calling methods such asgetCallbackProperty
as seen in many Laravel traits, so would you please share your opinion concerning this topic?