Skip to content

Commit

Permalink
update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
foladgar committed Jun 21, 2024
1 parent fd96925 commit 8c2d173
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
12 changes: 8 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Laravel OTP(One-Time Password)
![Test Status](https://img.shields.io/github/workflow/status/mohammad-fouladgar/laravel-otp/run-tests?label=tests)
[![Latest Stable Version](http://poser.pugx.org/fouladgar/laravel-otp/v)](https://packagist.org/packages/fouladgar/laravel-otp)
[![Total Downloads](http://poser.pugx.org/fouladgar/laravel-otp/downloads)](https://packagist.org/packages/fouladgar/laravel-otp)
[![Code Style Status](https://github.com/mohammad-fouladgar/laravel-otp/actions/workflows/php-cs-fixer.yml/badge.svg?branch=master)](https://github.com/mohammad-fouladgar/laravel-otp/actions/workflows/php-cs-fixer.yml)
[![Latest Version on Packagist](https://img.shields.io/packagist/v/fouladgar/laravel-otp.svg)](https://packagist.org/packages/fouladgar/laravel-otp)
![Test Status](https://img.shields.io/github/actions/workflow/status/mohammad-fouladgar/laravel-otp/run-tests.yml?label=tests)
![Code Style Status](https://img.shields.io/github/actions/workflow/status/mohammad-fouladgar/laravel-otp/php-cs-fixer.yml?label=code%20style)
![Total Downloads](https://img.shields.io/packagist/dt/fouladgar/laravel-otp)

## Introduction

Expand Down Expand Up @@ -53,6 +53,10 @@ OTP('+989389599530', 'token_123');
// or
OTP()->useProvider('users')
->validate('+989389599530', 'token_123');
// or
OTP()->useProvider('users')
->onlyConfirmToken()
->validate('+989389599530', 'token_123');
```

## Installation
Expand Down
6 changes: 1 addition & 5 deletions tests/OTPBrokerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -213,11 +213,7 @@ public function it_can_only_confirm_token_and_does_not_create_user(): void

$otp->send(self::MOBILE, false);

$user = $otp->onlyConfirmToken()
->validate(
self::MOBILE,
Cache::get(self::MOBILE)['token']
);
$user = $otp->onlyConfirmToken()->validate(self::MOBILE, Cache::get(self::MOBILE)['token']);

$this->assertInstanceOf(OTPNotifiable::class, $user);

Expand Down

0 comments on commit 8c2d173

Please sign in to comment.