Updated couch plugin, added error function to multiple functions in order to attempt to identify the issue (from Bradley-Holt reference).