This module provides some functions for faster 
logging of different actions on the DB.
        
        
- Version:
 - 
		
- 1.0
 
 
Members
- 
    
<inner> showConsoleOutput
 - 
    
    If true, it will output to the console, otherwise it will not output anything. It's good to turn it off in testing to increase readability. Leave on for debugging.
 
Methods
- 
    
<inner> log(type, username, tableName, entryID, message, Optional)
 - 
    
    Helper function to reduce duplication.
Parameters:
Name Type Description typestring Type of action taken: insert, update or delete. usernamestring User that has done that action. tableNamestring The table that was involved in the action. entryIDstring The key of the entry from the previous table that was involved in the action. messagestring Optional message that can provide more details about the action. Optionalfunction action, called with the result of insertQuery.  - 
    
<inner> logDelete(username, tableName, entryID, message, Optional)
 - 
    
    Call this to log a delete action.
Parameters:
Name Type Description usernamestring User that has done that action. tableNamestring The table that was involved in the action. entryIDstring The key of the entry from the previous table that was involved in the action. messagestring Optional message that can provide more details about the action. Optionalfunction action, called with the result of insertQuery.  - 
    
<inner> logInsert(username, tableName, entryID, message, Optional)
 - 
    
    Call this to log an insert action.
Parameters:
Name Type Description usernamestring User that has done that action. tableNamestring The table that was involved in the action. entryIDstring The key of the entry from the previous table that was involved in the action. messagestring Optional message that can provide more details about the action. Optionalfunction action, called with the result of insertQuery.  - 
    
<inner> logOther(username, tableName, entryID, message, Optional)
 - 
    
    Call this to log any other action. Say, requested editing, or attempted an invalid login etc.
Parameters:
Name Type Description usernamestring User that has done that action. tableNamestring The table that was involved in the action. entryIDstring The key of the entry from the previous table that was involved in the action. messagestring Message that provides details about the action. In this case the message is compulsory as it needs to explain what happened. Optionalfunction action, called with the result of insertQuery.  - 
    
<inner> logUpdate(username, tableName, entryID, message, Optional)
 - 
    
    Call this to log an update action.
Parameters:
Name Type Description usernamestring User that has done that action. tableNamestring The table that was involved in the action. entryIDstring The key of the entry from the previous table that was involved in the action. messagestring Optional message that can provide more details about the action. Optionalfunction action, called with the result of insertQuery.