Skip to content

Commit

Permalink
Support thecodingmachine/safe:^2
Browse files Browse the repository at this point in the history
  • Loading branch information
spawnia committed May 31, 2023
1 parent 1276d0c commit bca4706
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 9 deletions.
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,16 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

See [GitHub releases](https://github.com/mll-lab/str_putcsv/releases).

## Unreleased

## v1.1.0

### Added

- Support `thecodingmachine/safe:^2`

## v1.0.1

### Changed
Expand Down
15 changes: 10 additions & 5 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,27 +1,32 @@
{
"name": "mll-lab/str_putcsv",
"description": "The missing `str_putcsv` function for PHP",
"license": "MPL-2.0",
"keywords": [
"php",
"csv",
"str_getcsv",
"str_putcsv"
],
"homepage": "https://github.com/mll-lab/str_putcsv",
"license": "MPL-2.0",
"require": {
"php": "^7.2 || ^8.0",
"thecodingmachine/safe": "^1.3"
"thecodingmachine/safe": "^1.3 || ^2"
},
"require-dev": {
"ergebnis/composer-normalize": "^2.13",
"phpstan/phpstan": "^0.12.85",
"phpunit/phpunit": "^7 || ^8 || ^9",
"thecodingmachine/phpstan-safe-rule": "^1.0"
"phpstan/phpstan": "^1",
"phpunit/phpunit": "^2 || ^7 || ^8 || ^9",
"thecodingmachine/phpstan-safe-rule": "^1"
},
"autoload": {
"files": [
"str_putcsv.php"
]
},
"config": {
"allow-plugins": {
"ergebnis/composer-normalize": true
}
}
}
6 changes: 2 additions & 4 deletions str_putcsv.php
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
<?php

declare(strict_types=1);
<?php declare(strict_types=1);

if (!function_exists('str_putcsv')) {
/**
* Convert an array into a CSV string.
*
* @param array<mixed> $fields
* @param array<bool|float|int|string|Stringable|null> $fields
* The array to convert.
* @param string $delimiter [optional]
* Set the field delimiter (one character only).
Expand Down

0 comments on commit bca4706

Please sign in to comment.