Replace custom tap function with josephlavin/tap

This commit is contained in:
Oliver Davies 2018-08-31 00:35:25 +01:00
parent ad8582b8c9
commit 0774f465a2
3 changed files with 49 additions and 10 deletions

View file

@ -6,10 +6,11 @@
"watch": "composer run-script --timeout=0 generate -- --server --watch" "watch": "composer run-script --timeout=0 generate -- --server --watch"
}, },
"require": { "require": {
"php": "^5.5|^7.0",
"dflydev/embedded-composer": "^1.0@dev", "dflydev/embedded-composer": "^1.0@dev",
"josephlavin/tap": "^1.0",
"opdavies/sculpin-gist-embed-bundle": "^0.1", "opdavies/sculpin-gist-embed-bundle": "^0.1",
"opdavies/sculpin-twig-markdown-bundle": "^0.1", "opdavies/sculpin-twig-markdown-bundle": "^0.1",
"php": "^5.5|^7.0",
"sculpin/sculpin": "^2.1@dev", "sculpin/sculpin": "^2.1@dev",
"tsphethean/sculpin-related-posts-bundle": "~0.1.0", "tsphethean/sculpin-related-posts-bundle": "~0.1.0",
"wikimedia/composer-merge-plugin": "^1.4" "wikimedia/composer-merge-plugin": "^1.4"
@ -25,8 +26,7 @@
"psr-4": { "psr-4": {
"FormatTalksBundle\\": "src/FormatTalksBundle", "FormatTalksBundle\\": "src/FormatTalksBundle",
"WebsiteBundle\\": "src/WebsiteBundle" "WebsiteBundle\\": "src/WebsiteBundle"
}, }
"files": ["src/helpers.php"]
}, },
"autoload-dev": { "autoload-dev": {
"psr-4": { "psr-4": {

41
composer.lock generated
View file

@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically" "This file is @generated automatically"
], ],
"content-hash": "077bd67921b19ca9f0e2dbb0b3389f85", "content-hash": "a5025c0de779662a8b22145c20400a3e",
"packages": [ "packages": [
{ {
"name": "anahkiasen/underscore-php", "name": "anahkiasen/underscore-php",
@ -878,6 +878,45 @@
], ],
"time": "2012-11-02T14:49:47+00:00" "time": "2012-11-02T14:49:47+00:00"
}, },
{
"name": "josephlavin/tap",
"version": "v1.0.0",
"source": {
"type": "git",
"url": "https://github.com/josephlavin/tap.git",
"reference": "8733d96fb9b7d7dca204dfe59ec3ff34f3c69be9"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/josephlavin/tap/zipball/8733d96fb9b7d7dca204dfe59ec3ff34f3c69be9",
"reference": "8733d96fb9b7d7dca204dfe59ec3ff34f3c69be9",
"shasum": ""
},
"require": {
"php": ">=5.6.0"
},
"require-dev": {
"phpunit/phpunit": "~5.7"
},
"type": "library",
"autoload": {
"files": [
"src/tap.php",
"src/TapProxy.php"
]
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"description": "Stand alone port of Laravel's tap method.",
"keywords": [
"laravel",
"php",
"tap"
],
"time": "2017-09-24T23:36:28+00:00"
},
{ {
"name": "justinrainbow/json-schema", "name": "justinrainbow/json-schema",
"version": "5.2.1", "version": "5.2.1",

View file

@ -1,8 +1,8 @@
<?php <?php
function tap($value, $callback) //function tap($value, $callback)
{ //{
$callback($value); // $callback($value);
//
return $value; // return $value;
} //}