Skip to content

Commit

Permalink
Updated docs
Browse files Browse the repository at this point in the history
  • Loading branch information
eldadfux committed Dec 28, 2019
1 parent 88047a1 commit a32bfda
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,6 @@ $audit = new Audit($adapter);
A simple example for logging a user action in the audit DB.

```php
<?php

$userId = 'user-unique-id';
$event = 'deleted'; // Log specific action name
$resource = 'database/document-1'; // Resource unique ID (great for filtering specific logs)
Expand All @@ -72,8 +70,6 @@ $audit->log($userId, $event, $resource, $userAgent, $ip, $location, $data);
Fetch all logs by given user ID

```php
<?php

$logs = $this->audit->getLogsByUser(
'userId' // User unique ID
); // Returns an array of all logs for specific user
Expand All @@ -84,8 +80,6 @@ $logs = $this->audit->getLogsByUser(
Fetch all logs by given user ID and a specific action name

```php
<?php

$logs = $this->audit->getLogsByUserAndActions(
'userId', // User unique ID
['update', 'delete'] // List of selected action to fetch
Expand Down

0 comments on commit a32bfda

Please sign in to comment.