More whitespace cleanup.
This commit is contained in:
parent
c0322c9eae
commit
45c5be8468
43 changed files with 1116 additions and 1131 deletions
|
|
@ -3,9 +3,9 @@
|
|||
Lockfuncs module template
|
||||
|
||||
Copy this module one level up, to gamesrc/conf/, name it what
|
||||
you will and edit it to your liking.
|
||||
you will and edit it to your liking.
|
||||
|
||||
Then add the new module's path to the end of the tuple
|
||||
Then add the new module's path to the end of the tuple
|
||||
defined in settings.LOCK_FUNC_MODULES.
|
||||
|
||||
All functions defined globally in this module are assumed to be
|
||||
|
|
@ -18,15 +18,15 @@ arguments should be handled (excess ones calling magic (*args,
|
|||
**kwargs) to avoid errors). The lock function should handle all
|
||||
eventual tracebacks by logging the error and returning False.
|
||||
|
||||
See many more examples of lock functions in src.locks.lockfuncs.
|
||||
See many more examples of lock functions in src.locks.lockfuncs.
|
||||
|
||||
"""
|
||||
|
||||
def myfalse(accessing_obj, accessed_obj, *args, **kwargs):
|
||||
"""
|
||||
called in lockstring with myfalse().
|
||||
called in lockstring with myfalse().
|
||||
A simple logger that always returns false. Prints to stdout
|
||||
for simplicity, should use utils.logger for real operation.
|
||||
"""
|
||||
print "%s tried to access %s. Access denied." % (accessing_obj, accessed_obj)
|
||||
return False
|
||||
return False
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue