Skip to content
This repository was archived by the owner on Mar 14, 2024. It is now read-only.

Commit f04dc16

Browse files
authored
Merge pull request #6 from berteltorp/patch-1
Introduce the optional fallback parameter
2 parents e587507 + b7419b6 commit f04dc16

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

README.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,14 +21,19 @@ Here's how you can access your stored credentials. In this example we're retriev
2121
$credential = credentials('api-password');
2222
```
2323

24+
You can also specify a fallback value to be used if the credential for the specified key cannot be decrypted:
25+
26+
```php
27+
$credential = credentials('my-production-token', 'my-fallback-value');
28+
```
29+
2430
With the built-in edit command, you can easily edit your existing credentials. They will be automatically encrypted after saving your changes.
2531

2632
```bash
2733
php artisan credentials:edit
2834
```
2935
![Credentials Demo](https://beyondco.de/github/credentials.gif)
3036

31-
3237
## Installation
3338

3439
You can install the package via composer:

0 commit comments

Comments
 (0)