Skip to content

Commit

Permalink
dropped php 7 support #58
Browse files Browse the repository at this point in the history
  • Loading branch information
denisdulici committed Jan 18, 2022
1 parent 8f85eaf commit 87f8db3
Show file tree
Hide file tree
Showing 7 changed files with 23 additions and 24 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:

strategy:
matrix:
php: ['7.1', '7.2', '7.3', '7.4']
php: ['8.0', '8.1']

steps:
- name: Checkout code
Expand All @@ -34,4 +34,4 @@ jobs:
run: composer install --no-interaction --no-scripts --no-suggest --prefer-source

- name: Execute tests
run: vendor/bin/phpunit
run: vendor/bin/phpunit
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,6 @@
/tests/databases
/vendor
.DS_Store
.phpunit.result.cache
composer.phar
composer.lock
21 changes: 6 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@

This package intends to provide tools for formatting and conversion monetary values in an easy, yet powerful way for Laravel projects.

### Why not use the moneyphp package?
### Why not use the `moneyphp` package?

Because `moneyphp` uses the `intl` extension for number formatting. `intl` extension isn't present by default on PHP installs and can give [different results](http://moneyphp.org/en/latest/features/formatting.html#intl-formatter) in different servers.
Because it uses the `intl` extension for number formatting. `intl` extension isn't present by default on PHP installs and can give [different results](http://moneyphp.org/en/latest/features/formatting.html#intl-formatter) in different servers.

## Getting Started

Expand All @@ -22,24 +22,15 @@ Run the following command:
composer require akaunting/laravel-money
```

### 2. Register (for Laravel < 5.5)

Register the service provider in `config/app.php`

```php
Akaunting\Money\Provider::class,
```

### 3. Publish
### 2. Publish

Publish config file.

```bash
php artisan vendor:publish --tag=money
```


### 4. Configure
### 3. Configure

You can change the currencies information of your app from `config/money.php` file

Expand Down Expand Up @@ -97,15 +88,15 @@ currency('USD')

## Changelog

Please see [Releases](../../releases) for more information what has changed recently.
Please see [Releases](../../releases) for more information on what has changed recently.

## Contributing

Pull requests are more than welcome. You must follow the PSR coding standards.

## Security

If you discover any security related issues, please email security@akaunting.com instead of using the issue tracker.
Please review [our security policy](https://github.com/akaunting/laravel-money/security/policy) on how to report security vulnerabilities.

## Credits

Expand Down
7 changes: 7 additions & 0 deletions SECURITY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Security Policy

**PLEASE DON'T DISCLOSE SECURITY-RELATED ISSUES PUBLICLY, [SEE BELOW](#reporting-a-vulnerability).**

## Reporting a Vulnerability

If you discover any security related issues, please email security@akaunting.com instead of using the issue tracker.
10 changes: 5 additions & 5 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@
}
],
"require":{
"php":">=5.6.4",
"illuminate/support":">=5.4",
"illuminate/view":">=5.4"
"php":">=8.0",
"illuminate/support":">=8.0",
"illuminate/view":">=8.0"
},
"require-dev":{
"mockery/mockery":">=1.0",
"phpunit/phpunit":">=5.7"
"mockery/mockery":">=1.4",
"phpunit/phpunit":">=9.0"
},
"autoload":{
"psr-4":{
Expand Down
2 changes: 1 addition & 1 deletion src/Currency.php
Original file line number Diff line number Diff line change
Expand Up @@ -480,7 +480,7 @@ public function toJson($options = 0)
*
* @return array
*/
public function jsonSerialize()
public function jsonSerialize(): mixed
{
return $this->toArray();
}
Expand Down
2 changes: 1 addition & 1 deletion src/Money.php
Original file line number Diff line number Diff line change
Expand Up @@ -866,7 +866,7 @@ public function toJson($options = 0)
*
* @return array
*/
public function jsonSerialize()
public function jsonSerialize(): mixed
{
return $this->toArray();
}
Expand Down

0 comments on commit 87f8db3

Please sign in to comment.