conversations
listlengths
2
3
source
stringclasses
1 value
stack
stringclasses
1 value
[ { "from": "system", "value": "Change config to production values\n" }, { "from": "human", "value": "<?php\n\nreturn [\n\n /*\n |--------------------------------------------------------------------------\n | Config options for the zKill bot\n |-----------------------------------------...
php
chosen
[ { "from": "system", "value": "Support all Enumerables in proxy\n" }, { "from": "human", "value": "<?php\n\nnamespace Illuminate\\Support;\n\n/**\n * @mixin \\Illuminate\\Support\\Collection\n */\nclass HigherOrderCollectionProxy\n{\n /**\n * The collection being operated on.\n *\n ...
php
chosen
[ { "from": "system", "value": "Fix Generator verification in loop()\n" }, { "from": "human", "value": "<?php\n\ndeclare(strict_types=1);\n\nnamespace Funktions;\n\nuse Exception;\n\n/**\n * Return a value based on a test\n *\n * @param boolean $test\n * @param callable $truthy\n * @param callable...
php
chosen
[ { "from": "system", "value": "Convert a HRExpr to an array.\n" }, { "from": "human", "value": "<?php\n/**\n * This file is part of DomainSpecificQuery\n *\n * For the full copyright and license information, please view the LICENSE\n * file that was distributed with this source code.\n *\n * @au...
php
chosen
[ { "from": "system", "value": "Allow for data as well as file upload.\n" }, { "from": "human", "value": "<?php\n\nnamespace Metrique\\Plonk\\Http\\Requests;\n\nuse Metrique\\Plonk\\Http\\Requests\\Request;\n\nclass PlonkStoreRequest extends Request\n{\n /**\n * Determine if the user is aut...
php
chosen
[ { "from": "system", "value": "Allow multiple IPs in ATOM_DEBUG_IP\n" }, { "from": "human", "value": "<?php\n\n// This check prevents access to debug front controllers that are deployed by\n// accident to production servers. Feel free to remove this, extend it or make\n// something more sophistic...
php
chosen
[ { "from": "system", "value": "Fix default size entity constructor params & fix mistake in parent constructor call\n" }, { "from": "human", "value": "<?php\n\nnamespace Ivory\\GoogleMapBundle\\Entity;\n\nuse Ivory\\GoogleMapBundle\\Model\\Base\\Size as BaseSize;\n\n/**\n * Size entity which descr...
php
chosen
[ { "from": "system", "value": "Add a couple todo's in the reset functions" }, { "from": "human", "value": "<?php\n\nfunction reset_new($Userid) {\n global $ResetsTable;\n $code = reset_generate_code();\n $created = time();\n $sql = \"INSERT INTO $ResetsTable\n (Userid...
php
chosen
[ { "from": "system", "value": "Add Dependency Injection (fixed build failed problem)\n" }, { "from": "human", "value": "<?php\n/**\n * Created by PhpStorm.\n * User: hong\n * Date: 11/7/16\n * Time: 2:48 PM\n */\n\nnamespace O\\Tests;\n\n\nuse O\\DesignPatterns\\Structural\\DependencyInjection\\D...
php
chosen
[ { "from": "system", "value": "Fix mixin test case again\n" }, { "from": "human", "value": "<?php\n\nnamespace Maghead\\Schema;\n\nuse AuthorBooks\\Model\\AuthorSchema;\nuse PHPUnit\\Framework\\TestCase;\n\n/**\n * @group schema\n */\nclass MixinDeclareSchemaTest extends TestCase\n{\n public f...
php
chosen
[ { "from": "system", "value": "REmove the logout to give way to the new logout being implemented by Joemel.\n" }, { "from": "human", "value": "<body>\n <!-- topbar starts -->\n <div class=\"navbar navbar-default\" role=\"navigation\">\n <div class=\"banner\" style=\"background-color:...
php
chosen
[ { "from": "system", "value": "Use of id (primary key) is hardcoded in select_multiple column\n\nNot all setups have id as the primary key. Instead get the primary\nkey name from the given model and use that in the pluck method.\n" }, { "from": "human", "value": "{{-- relationships with pivot tab...
php
chosen
[ { "from": "system", "value": "Add missing implementation in `UserFollowUserNotificationObject`\n\nFixes 82ba990ddcd929e45c952a312340f86a56eecb19\n" }, { "from": "human", "value": "<?php\nnamespace wcf\\system\\user\\notification\\object;\nuse wcf\\data\\user\\follow\\UserFollow;\nuse wcf\\data\\...
php
chosen
[ { "from": "system", "value": "Use FQCN and automatically add BecklynRadBundle" }, { "from": "human", "value": "<?php\n\nuse Symfony\\Component\\HttpKernel\\Kernel;\nuse Symfony\\Component\\Config\\Loader\\LoaderInterface;\n\nclass AppKernel extends Kernel\n{\n public function registerBundles(...
php
chosen
[ { "from": "system", "value": "Fix non existing Model\\AlbumTableGateway::class FQN\n" }, { "from": "human", "value": "<?php\n\nnamespace Album;\n\nuse Zend\\Db\\Adapter\\Adapter;\nuse Zend\\Db\\ResultSet\\ResultSet;\nuse Zend\\Db\\TableGateway\\TableGateway;\nuse Zend\\ModuleManager\\Feature\\Co...
php
chosen
[ { "from": "system", "value": "Make test possible when the package is installed\n" }, { "from": "human", "value": "<?php\n\nrequire_once __DIR__ . DIRECTORY_SEPARATOR . '..' . DIRECTORY_SEPARATOR . 'vendor' . DIRECTORY_SEPARATOR . 'autoload.php';\n\n" }, { "from": "gpt", "value": "<?p...
php
chosen
[ { "from": "system", "value": "Configure tests to run when included as a dependency\n" }, { "from": "human", "value": "<?php\n\n$loader = require __DIR__.'/../vendor/autoload.php';\n$loader->addPsr4('React\\\\Promise\\\\', __DIR__);\n" }, { "from": "gpt", "value": "<?php\n\n$loader = ...
php
chosen
[ { "from": "system", "value": "Update to use the Facade\n\nUpdate TCPDF.php" }, { "from": "human", "value": "<?php\n\nnamespace Elibyy\\TCPDF;\n\nuse Config;\n\nclass TCPDF\n{\n\tprotected static $format;\n\t\n\tprotected $app;\n\t/** @var TCPDFHelper */\n\tprotected $tcpdf;\n\n\tpublic function...
php
chosen
[ { "from": "system", "value": "Add unit tests for diffInHours\n" }, { "from": "human", "value": "<?php\n\n/*\n * This file is part of the Carbon package.\n *\n * (c) Brian Nesbitt <brian@nesbot.com>\n *\n * For the full copyright and license information, please view the LICENSE\n * file that was ...
php
chosen
[ { "from": "system", "value": "Change session profile array to associative.\n" }, { "from": "human", "value": "<?php\nsession_start();\n\n\n$profiles_raw = shell_exec('netsh wlan show profiles');\n\npreg_match_all(\"/(All|Current) User Profile +: (.+)/\", $profiles_raw, $profiles);\narray_shift($...
php
chosen
[ { "from": "system", "value": "Fix some whitespace that crept in.\n" }, { "from": "human", "value": "<?php\n\n/**\n * A (static) helper class that contains logging related functionality.\n */\nclass Logger\n{\n\tpublic static $names = array(LOG_DEBUG => 'debug', LOG_INFO => 'info', LOG_ERR => 'er...
php
chosen
[ { "from": "system", "value": "Add label to be translated for form\n\nFor the moment the form is not translated." }, { "from": "human", "value": "<?php\n\nnamespace Lexik\\Bundle\\TranslationBundle\\Form;\n\nuse Symfony\\Component\\Form\\AbstractType;\nuse Symfony\\Component\\Form\\FormBuilderInt...
php
chosen
[ { "from": "system", "value": "Allow multiple sequential rpc requests\n" }, { "from": "human", "value": "<?php\n\nnamespace OldSound\\RabbitMqBundle\\RabbitMq;\n\nuse OldSound\\RabbitMqBundle\\RabbitMq\\BaseAmqp;\nuse PhpAmqpLib\\Message\\AMQPMessage;\n\nclass RpcClient extends BaseAmqp\n{\n p...
php
chosen
[ { "from": "system", "value": "Add safety check to prevent `removeDirectory` from doing bad things\n" }, { "from": "human", "value": "<?php\n\n/**\n * To rebuild the `snapshots` directory after changing\n * files in `source`, run `php tests/rebuild.php`.\n */\nshell_exec('./jigsaw build testing')...
php
chosen
[ { "from": "system", "value": "Use implode instead of join function\n" }, { "from": "human", "value": "<?php\n\n/*\n * This file is part of the SKTwigExtensionsBundle package.\n *\n * (c) Sebastian Kroczek <sk@xbug.de>\n *\n * For the full copyright and license information, please view the LICENS...
php
chosen
[ { "from": "system", "value": "Return css and js for a step\n" }, { "from": "human", "value": "<?php\n\n/**\n * @author: Gabriel BONDAZ <gabriel.bondaz@idci-consulting.fr>\n * @license: MIT\n */\n\nnamespace IDCI\\Bundle\\StepBundle\\Twig;\n\nuse IDCI\\Bundle\\StepBundle\\Navigation\\NavigatorIn...
php
chosen
[ { "from": "system", "value": "Fix - iterable type introduced in PHP 7.1\n" }, { "from": "human", "value": "<?php\n\ndeclare(strict_types=1);\n\nnamespace Rector\\ValueObject;\n\nfinal class PhpVersionFeature\n{\n /**\n * @var string\n */\n public const SCALAR_TYPES = '7.0';\n\n ...
php
chosen
[ { "from": "system", "value": "Hide CC icon from the footer\n" }, { "from": "human", "value": "<?php\n\nclass HitchwikiHooks {\n\n\t/**\n\t * Handler for BeforePageDisplay\n\t * @param OutputPage $out\n\t * @param Skin $skin\n\t * @return bool\n\t */\n\tstatic function onBeforePageDisplay( &$out,...
php
chosen
[ { "from": "system", "value": "Update DI extension to recognize new parameter\n\nMake sure we fetch avalange_imagine.not_found_images parameter collection\ninto imagine.not_found_images parameter.\n" }, { "from": "human", "value": "<?php\n\nnamespace Avalanche\\Bundle\\ImagineBundle\\DependencyIn...
php
chosen
[ { "from": "system", "value": "Correct bug on doctrine diff file when updating DB\n" }, { "from": "human", "value": "<?php\n\nnamespace DoctrineMigrations;\n\nuse Doctrine\\DBAL\\Migrations\\AbstractMigration;\nuse Doctrine\\DBAL\\Schema\\Schema;\n\n/**\n * Auto-generated Migration: Please modify...
php
chosen
[ { "from": "system", "value": "Add quotes to cron information page, for the example crontab file\n" }, { "from": "human", "value": "<?php\n\n$this->data['header'] = 'Cron information page';\n$this->includeAtTemplateBase('includes/header.php');\n\n?>\n<div id=\"content\">\n\n\t<p>Cron is a way to ...
php
chosen
[ { "from": "system", "value": "Remove postRenderPlugin comments in embed HTML\n\nThese can break if -- modifier is used inside commented out html (-- ends a html comment :/)\n" }, { "from": "human", "value": "<?php\nclass Kwc_Advanced_IntegratorTemplate_Embed_ContentSender extends Kwf_Component_A...
php
chosen
[ { "from": "system", "value": "[Serializer] Add a docblock to help type hinting\n\n" }, { "from": "human", "value": "<?php\n\n/*\n * This file is part of the Symfony package.\n *\n * (c) Fabien Potencier <fabien@symfony.com>\n *\n * For the full copyright and license information, please view the ...
php
chosen
[ { "from": "system", "value": "Add pequena mudança para testes com ajax\n" }, { "from": "human", "value": "<?php \n/**\n * App ajax\n *\n * @package App-Admin\n * @subpackage Admim \n */\n\n\n\t@header( 'Content-Type: text/html; charset=utf-8' );\n\t@header( 'X-Robots-Tag: noindex' );\n\n\n\t$dad...
php
chosen
[ { "from": "system", "value": "Add console command for adding items easily\n" }, { "from": "human", "value": "<?php\n\nnamespace App\\Console;\n\nuse Illuminate\\Console\\Scheduling\\Schedule;\nuse Illuminate\\Foundation\\Console\\Kernel as ConsoleKernel;\n\nclass Kernel extends ConsoleKernel\n{\...
php
chosen
[ { "from": "system", "value": "Fix model factory faker for user\n" }, { "from": "human", "value": "<?php\n\n/*\n|--------------------------------------------------------------------------\n| Model Factories\n|--------------------------------------------------------------------------\n|\n| Here yo...
php
chosen
[ { "from": "system", "value": "Fix a use bug on FieldType\n" }, { "from": "human", "value": "<?php\n\nnamespace Bolt\\Extension\\Leskis\\BoltFieldGeojson\\Field;\n\nuse Bolt\\Storage\\Field\\FieldInterface;\nuse Doctrine\\DBAL\\Types\\Type;\n\n/**\n * GeojsonField class.\n *\n * @author Nicolas B...
php
chosen
[ { "from": "human", "value": "Test coverage for the pinterest template params\n" }, { "from": "gpt", "value": "<?php\nrequire_once PATH_THIRD .'socialeesta/TemplateParams/PinterestPinIt.php';\n\nclass PinterestPinItTemplateParams extends Testee_unit_test_case {\n private $_params;\n\n \n ...
php
chosen
[ { "from": "system", "value": "Convert exception creation to leaveNode()\n" }, { "from": "human", "value": "<?php\n\n/*\n * This file is part of Psy Shell.\n *\n * (c) 2012-2015 Justin Hileman\n *\n * For the full copyright and license information, please view the LICENSE\n * file that was distri...
php
chosen
[ { "from": "system", "value": "Fix model relationship and ready to set online\n" }, { "from": "human", "value": "<?php\n\nnamespace App;\n\nuse Illuminate\\Database\\Eloquent\\Model;\n\nclass Node extends Model\n{\n\t// Properties\n\n\tprotected $dateFormat = 'U';\n\t// Relationships\n\n\t/**\n\t...
php
chosen
[ { "from": "system", "value": "Remove email sending in default controller\n" }, { "from": "human", "value": "<?php\n\nnamespace AppBundle\\Controller;\n\nuse Sensio\\Bundle\\FrameworkExtraBundle\\Configuration\\Route;\nuse Symfony\\Bundle\\FrameworkBundle\\Controller\\Controller;\n\nclass Default...
php
chosen
[ { "from": "system", "value": "Check if we actually have an array.\n" }, { "from": "human", "value": "<?php\n/**\n * Validate array types.\n *\n * @package HylianShield\n * @subpackage Validator\n * @copyright 2014 Noë Snaterse.\n */\n\nnamespace HylianShield\\Validator\\CoreArray;\n\n/**\n * Cor...
php
chosen
[ { "from": "system", "value": "BAP-4251: Create trait for activities Extend* classes\n- add associations stub methods\n" }, { "from": "human", "value": "<?php\n\nnamespace Oro\\Bundle\\EmailBundle\\Model;\n\nclass ExtendEmail\n{\n}\n" }, { "from": "gpt", "value": "<?php\n\nnamespace O...
php
chosen
[ { "from": "system", "value": "Add missing docblocks to the role controller\n" }, { "from": "human", "value": "<?php\n\nnamespace App\\Http\\Controllers;\n\nuse Illuminate\\Http\\Request;\nuse App\\Http\\Requests;\n\nuse App\\Roles;\n\nclass RolesController extends Controller\n{\n public funct...
php
chosen
[ { "from": "system", "value": "Fix typo and turn callbacks off, revisit later\n" }, { "from": "human", "value": "<?php\nnamespace FluxCtrl\\Test\\Factory;\n\nuse Gourmet\\Muffin\\TestSuite\\TestFactory;\n\nclass ItemFactory extends TestFactory\n{\n public $feed_id = 'factory|FluxCtrl\\Model\\E...
php
chosen
[ { "from": "system", "value": "Fix example script so it looks for 'Bang' rather than 'bang'\n" }, { "from": "human", "value": "<?php\ninclude('vendor/autoload.php');\n\nuse TddFizzBuzz\\FizzBuzzBang;\n\n$fizzer = new FizzBuzzBang();\n\nforeach(range(1,5000) as $num) {\n $message = $fizzer->run...
php
chosen
[ { "from": "system", "value": "Create cookie on game first run\n" }, { "from": "human", "value": "<?php\n\n include(\"/home/c0smic/secure/data_db_settings.php\");\n\n $body = file_get_contents('php://input');\n\n $stime = \"\";\n $etime = \"\";\n $moves = \"\";\n\n function pars...
php
chosen
[ { "from": "system", "value": "Align Exception test to coding style for test suite\n" }, { "from": "human", "value": "<?php\n\n/**\n * League.Csv (https://csv.thephpleague.com)\n *\n * (c) Ignace Nyamagana Butera <nyamsprod@gmail.com>\n *\n * For the full copyright and license information, please...
php
chosen
[ { "from": "system", "value": "Switch to function to supress error\n" }, { "from": "human", "value": "<?php\n\nnamespace Cjm\\Behat;\n\nuse Behat\\Gherkin\\Node\\FeatureNode;\nuse Behat\\Gherkin\\Node\\ScenarioInterface;\nuse Behat\\Gherkin\\Node\\TaggedNodeInterface;\nuse Cjm\\Testing\\SemVer\\T...
php
chosen
[ { "from": "system", "value": "Change refresh token only when is an API login and new JWT is generated\n" }, { "from": "human", "value": "<?php\n\nnamespace Gesdinet\\JWTRefreshTokenBundle\\EventListener;\n\nuse FOS\\UserBundle\\Event\\UserEvent;\nuse FOS\\UserBundle\\FOSUserEvents;\nuse FOS\\Use...
php
chosen
[ { "from": "system", "value": "Remove router as service, add autoloader\n" }, { "from": "human", "value": "<?php\n\n// PSR-4 autoloader\n\nrequire MICROAPI_PATH . DIRECTORY_SEPARATOR . 'Autoloader.php';\n$autoloader = new \\MicroAPI\\Autoloader();\n$autoloader->addNamespace('App', APP_PATH);\n$au...
php
chosen
[ { "from": "system", "value": "Implement get() function with apc_fetch()\n" }, { "from": "human", "value": "<?php\n class Better_PHP_Cache\n {\n public function __construct()\n {\n\n }\n\n public function add($entry_name, $entry_value, $time_to_live)\n {\n...
php
chosen
[ { "from": "system", "value": "Add comment to test pushing\n" }, { "from": "human", "value": "<?php\n\nnamespace CodeJetter\\components\\user;\n\nuse CodeJetter\\core\\BaseConfig;\n\nclass UserConfig extends BaseConfig\n{\n protected static $configs = [\n 'testUser' => 'testUser',\n ...
php
chosen
[ { "from": "system", "value": "Change config path to public path\n" }, { "from": "human", "value": "<?php\n\n/*\n * This file is part of the Laravel Facebook Account-Kit package.\n *\n * (c) Ibraheem Adeniyi <ibonly01@gmail.com>\n *\n * For the full copyright and license information, please view ...
php
chosen
[ { "from": "system", "value": "Fix @variable directive without arguments\n" }, { "from": "human", "value": "<?php\n\nnamespace Milax\\Mconsole\\Providers;\n\nuse Illuminate\\Support\\ServiceProvider;\nuse Milax\\Mconsole\\Models\\MconsoleUploadPreset;\nuse Milax\\Mconsole\\Models\\Variable;\nuse ...
php
chosen
[ { "from": "system", "value": "Add 4 more project icons\n\nSummary: Adds 4 more icons.\n\nTest Plan: Tested editing a project\n\nReviewers: epriestley\n\nReviewed By: epriestley\n\nSubscribers: epriestley, Korvin\n\nDifferential Revision: https://secure.phabricator.com/D9919\n" }, { "from": "human", ...
php
chosen
[ { "from": "system", "value": "Update the make paginator method to receive the table key\n" }, { "from": "human", "value": "<?php\n\nnamespace Michaeljennings\\Carpenter\\Contracts;\n\ninterface Paginator\n{\n /**\n * Create a new paginator.\n *\n * @param string|integer $total\n ...
php
chosen
[ { "from": "system", "value": "[n/a] Fix type hinting return for setMetadata method\n" }, { "from": "human", "value": "<?php\n\nnamespace Kerox\\Messenger\\Model;\n\nuse Kerox\\Messenger\\Helper\\ValidatorTrait;\n\nclass ThreadControl implements \\JsonSerializable\n{\n use ValidatorTrait;\n\n ...
php
chosen
[ { "from": "system", "value": "Add twitter location and description fields\n" }, { "from": "human", "value": "<?php\n\nnamespace Laravel\\Socialite\\One;\n\nuse InvalidArgumentException;\n\nclass TwitterProvider extends AbstractProvider\n{\n /**\n * {@inheritdoc}\n */\n public funct...
php
chosen
[ { "from": "system", "value": "Allow to run from any directory.\nUse from_db\n\n\ngit-svn-id: bc46a84f389827447d29da2b7e0abe424efe24cf@4441 cbe1a1ec-7179-4919-8e32-4551e8279a00\n" }, { "from": "human", "value": "#! /usr/bin/env php\n<?\ninclude('../config.php');\ninclude(mnminclude.'webimages.php...
php
chosen
[ { "from": "system", "value": "Use positional params for sprintf\n" }, { "from": "human", "value": "<?php\n\n\nnamespace Beanie\\Exception;\n\n\nuse Beanie\\Command;\nuse Beanie\\Exception;\nuse Beanie\\Server\\Server;\n\nclass DeadlineSoonException extends Exception\n{\n const DEFAULT_CODE = ...
php
chosen
[ { "from": "system", "value": "Make fallback XML root element be in correct namespace\n" }, { "from": "human", "value": "<?php\nnamespace PharIo\\Phive {\n\n abstract class XmlRepository {\n\n /**\n * @var string\n */\n private $filename = '';\n\n /**\n ...
php
chosen
[ { "from": "system", "value": "Change default name to .csv instead of .txt\n" }, { "from": "human", "value": "<?\n$fn= \"order.txt\";\nif (preg_match('/^([-A-Za-z0-9_])+\\\\.([A-Za-z0-9]+)$/', $_REQUEST['fn'])) {\n $fn= $_REQUEST['fn'];\n}\nheader('Content-Type: application/tsv'); \nheader('Cont...
php
chosen
[ { "from": "system", "value": "Change constructor argument to use interface\n" }, { "from": "human", "value": "<?php\n\ndeclare(strict_types=1);\n\nnamespace Budgegeria\\Bundle\\IntlFormatBundle\\Twig;\n\nuse Budgegeria\\IntlFormat\\IntlFormat;\nuse Twig\\Extension\\AbstractExtension;\nuse Twig\\...
php
chosen
[ { "from": "system", "value": "Fix order total shipping rules\n" }, { "from": "human", "value": "<?php\n\n/*\n * This file is part of the Sylius package.\n *\n * (c) Paweł Jędrzejewski\n *\n * For the full copyright and license information, please view the LICENSE\n * file that was distributed wi...
php
chosen
[ { "from": "system", "value": "Disable log component on test environment\n" }, { "from": "human", "value": "<?php\nreturn [\n 'request' => [\n 'class' => \\blink\\http\\Request::class,\n 'middleware' => [],\n ],\n 'response' => [\n 'class' => \\blink\\http\\Response:...
php
chosen
[ { "from": "system", "value": "Add a template directory constant.\n" }, { "from": "human", "value": "<?php\n\n/**\n * Define Constants.\n */\ndefine('ADMIN_DIR', get_template_directory() .'/admin');\ndefine('ADMIN_URL', get_template_directory_uri() .'/admin');\n\ndefine('AUTHOR', 'Vincent Klaiber...
php
chosen
[ { "from": "system", "value": "Implement the promises of the user interface...\n" }, { "from": "human", "value": "<?php\nnamespace Phpws\\Core;\n\nclass WebSocketUser implements \\Phpws\\Interfaces\\WebsocketUser {\n\n public $socket;\n public $id;\n public $watcher;\n public $headers = NULL;...
php
chosen
[ { "from": "system", "value": "Fix wrong type for debug\n" }, { "from": "human", "value": "<?php\n\nnamespace App;\n\nuse Matthias\\SymfonyConsoleForm\\Bundle\\SymfonyConsoleFormBundle;\nuse Symfony\\Bundle\\FrameworkBundle\\FrameworkBundle;\nuse Symfony\\Bundle\\TwigBundle\\TwigBundle;\nuse Symf...
php
chosen
[ { "from": "system", "value": "Rename paramater arguments as inputs\n" }, { "from": "human", "value": "<?php\n/**\n * @file\n * Contains Drupal\\AppConsole\\Command\\Helper\\ChainCommandHelper.\n */\n\nnamespace Drupal\\AppConsole\\Command\\Helper;\n\nuse Symfony\\Component\\Console\\Helper\\Help...
php
chosen
[ { "from": "system", "value": "Join template on related content query" }, { "from": "human", "value": "<?php\n\nnamespace Opifer\\CmsBundle\\Controller;\n\nuse Symfony\\Bundle\\FrameworkBundle\\Controller\\Controller;\nuse Symfony\\Component\\HttpFoundation\\Response;\n\n/**\n * Template Controll...
php
chosen
[ { "from": "system", "value": "Add ID of authorized user on facebook auth request\n" }, { "from": "human", "value": "<?php\n\nnamespace App\\Http\\Controllers\\Auth;\n\nuse App\\Http\\Controllers\\Controller;\n\nuse Illuminate\\Support\\Facades\\Auth;\nuse Illuminate\\Support\\Facades\\Input;\nus...
php
chosen
[ { "from": "system", "value": "Allow content editors to edit banners.\n" }, { "from": "human", "value": "<?php\n\nclass BannerImage extends DataObject{\n\n\tprivate static $db = array(\n\t\t'Title' => 'Varchar(255)',\n\t\t'SubTitle' => 'Varchar(255)',\n\t\t'Link' => 'LinkField',\n\t\t'Sort' => 'I...
php
chosen
[ { "from": "system", "value": "Fix url resolution with regards to querysting parameters.\n" }, { "from": "human", "value": "<?php\n\nnamespace Markup\\OEmbedBundle\\Client;\n\nuse Markup\\OEmbedBundle\\Provider\\ProviderInterface;\n\n/**\n* A superclass for client implementations.\n*/\nabstract c...
php
chosen
[ { "from": "system", "value": "Disable dashboard due to Google error API\n" }, { "from": "human", "value": "<?php\n\n/**\n *\n * @package symfony\n * @subpackage plugin\n * @author Vincent CHALAMON <vincentchalamon@gmail.com>\n * @version SVN: $Id: actions.class.php 23319 2009-10-25 12:...
php
chosen
[ { "from": "system", "value": "Use the description, remove debug reference.\n\n\ngit-svn-id: 3b6cb4556d214d66df54bca2662d7ef408f367bf@3232 46e82423-29d8-e211-989e-002590a4cdd4\n" }, { "from": "human", "value": "<?php\n\t#\n\t# $Id: ports-broken.php,v 1.1.2.19 2005-01-23 03:12:54 dan Exp $\n\t#\n\...
php
chosen
[ { "from": "system", "value": "[UserMilestone] Use PHP 7.1 type declarations\n" }, { "from": "human", "value": "<?php\n/**\n * @author Pierre-Henry Soria <hi@ph7.me>\n * @copyright (c) 2018-2019, Pierre-Henry Soria. All Rights Reserved.\n * @license MIT License; See PH7.LICENS...
php
chosen
[ { "from": "system", "value": "Make each location a link to the edit page instead of using a button\n" }, { "from": "human", "value": "<!-- resources/views/admin/location_index.blade.php -->\n\n@extends('layouts.app')\n\n@section('content')\n<h2>Locations</h2>\n\n<table class=\"table\"\n\t<tbody>...
php
chosen
[ { "from": "system", "value": "Fix default value for is_user_setting\n\nSigned-off-by: Euan T <bb3cb0933b629e9456c636be3c1aa8b281a75c82@gmail.com>\n" }, { "from": "human", "value": "<?php\n\nuse Illuminate\\Database\\Schema\\Blueprint;\nuse Illuminate\\Database\\Migrations\\Migration;\n\nclass Cr...
php
chosen
[ { "from": "system", "value": "Add the invalid hook message back" }, { "from": "human", "value": "<?php\r\nnamespace autoauth;\r\n\r\n$config = require('config.php');\r\n$layout = new layout\\Page(\"pages/index.{$config->hook->userRole()}.xml\");\r\n\r\nif($_SERVER['REQUEST_METHOD'] === 'POST')\r...
php
chosen
[ { "from": "system", "value": "Set a starting point for the datatables\n" }, { "from": "human", "value": "<?php\nnamespace MindOfMicah\\LaravelDatatables;\n\nuse Illuminate\\Http\\JsonResponse;\n\nclass Datatable\n{\n protected $model;\n protected $columns;\n\n\tpublic function __construct(...
php
chosen
[ { "from": "system", "value": "Make plugins command always be verbose\n" }, { "from": "human", "value": "<?php\n\n/*\n * This file is part of Rocketeer\n *\n * (c) Maxime Fabre <ehtnam6@gmail.com>\n *\n * For the full copyright and license information, please view the LICENSE\n * file that was di...
php
chosen
[ { "from": "system", "value": "Extend SettingsAction instead of just Action\n\nThis way a lot of things (login, etc.) are handled for us.\n" }, { "from": "human", "value": "<?php\nif (!defined('GNUSOCIAL')) {\n exit(1);\n}\n\nclass BrowserNotificationsSettingsAction extends Action\n{\n func...
php
chosen
[ { "from": "system", "value": "Allow user scaling and remove max scale" }, { "from": "human", "value": "<!DOCTYPE html>\n<html class=\"no-js\">\n<head>\n <meta charset=\"utf-8\">\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge\">\n <meta name=\"viewport\" content=\"width=device-width,...
php
chosen
[ { "from": "system", "value": "Fix name of login route\n" }, { "from": "human", "value": "<?php\n\nnamespace App\\Http\\Middleware;\n\nuse Illuminate\\Auth\\Middleware\\Authenticate as Middleware;\n\nclass Authenticate extends Middleware\n{\n /**\n * Get the path the user should be redirec...
php
chosen
[ { "from": "system", "value": "Enable all taxons upon migration\n" }, { "from": "human", "value": "<?php\n\ndeclare(strict_types=1);\n\nnamespace Sylius\\Migrations;\n\nuse Doctrine\\DBAL\\Schema\\Schema;\nuse Doctrine\\Migrations\\AbstractMigration;\n\n/**\n * Auto-generated Migration: Please mo...
php
chosen
[ { "from": "system", "value": "Fix logic error in regex for index route\n" }, { "from": "human", "value": "<?php\n/**\n* \n*/\nclass UriParser {\n\t\n\tstatic function isIndexRoute(string $uri, array $models): bool{\n\t\t$indexRegex = '`^'.implode('|', array_map(function($model){ return $model::s...
php
chosen
[ { "from": "system", "value": "Resolve namespace-level identifiers in the enclosing namespace.\n" }, { "from": "human", "value": "<?php\nnamespace Phortress;\n\nuse PhpParser\\Node\\Stmt;\nuse PhpParser\\Node\\Stmt\\Class_;\n\n/**\n * Namespace Continuation Environments: these are continuation of...
php
chosen
[ { "from": "system", "value": "Allow to use the middleware class name instead" }, { "from": "human", "value": "<?php namespace Barryvdh\\StackMiddleware;\n\nuse Closure;\nuse Illuminate\\Contracts\\Container\\Container;\n\nclass Wrapper\n{\n /** @var Container $container */\n protected $con...
php
chosen
[ { "from": "system", "value": "Update example to include URI path" }, { "from": "human", "value": "<?php\n\nuse Clue\\React\\Buzz\\Browser;\nuse Clue\\React\\Buzz\\Message\\Response;\n\nrequire __DIR__ . '/../vendor/autoload.php';\n\n$loop = React\\EventLoop\\Factory::create();\n$client = new Bro...
php
chosen
[ { "from": "system", "value": "Remove length tests from Binary column, tested in abstraction\n" }, { "from": "human", "value": "<?php\n/**\n * Zend Framework (http://framework.zend.com/)\n *\n * @link http://github.com/zendframework/zf2 for the canonical source repository\n * @copyright Copy...
php
chosen
[ { "from": "system", "value": "Add docblock to test function\n" }, { "from": "human", "value": "<?php\n\nnamespace MarkWilson\\Test;\n\nrequire_once __DIR__ . '/../VerbalExpression.php';\n\nuse MarkWilson\\VerbalExpression;\n\n/**\n * Class VerbalExpressionOutputTest\n *\n * @package MarkWilson\\...
php
chosen
[ { "from": "system", "value": "Fix : Correct event handler base class.\n" }, { "from": "human", "value": "<?php\n\nnamespace SecucardConnect\\Event;\n\n\nuse SecucardConnect\\Product\\General\\Model\\Event;\n\nabstract class AbstractEventHandler implements EventHandler\n{\n /**\n * A user ...
php
chosen
[ { "from": "system", "value": "Add `package *` commands to the list of protected commands.\n\nSee https://github.com/wp-cli/package-command/issues/10\n" }, { "from": "human", "value": "<?php\n\nnamespace WP_CLI\\Bootstrap;\n\n/**\n * Class DefineProtectedCommands.\n *\n * Define the commands that...
php
chosen
[ { "from": "system", "value": "Make code more self documenting and remove (* title).\n" }, { "from": "human", "value": "<?php\nheader('Content-Type: application/json');\nheader('Content-type: text/html; charset=UTF-8');\n\ninclude_once(\"config/config.php\");\ninclude_once(\"inc/params.php\");\ni...
php
chosen
[ { "from": "system", "value": "Resolve Faker\\Generator out of the container if it is bound\n\nIf Faker\\Generator is bound in the container then use that instance instead of creating a default version. This allows you to bind your own custom Faker\\Generator and add custom faker providers which will be avai...
php
chosen
[ { "from": "system", "value": "Enable errors in the right place.\n" }, { "from": "human", "value": "<?php\nrequire __DIR__ . '/../vendor/autoload.php';\nsession_save_path('.\\sessions');\nsession_start();\nif ($debug) {\n error_reporting(E_ALL);\n ini_set('display_errors', 'On');\n}\ndefine('BA...
php
chosen
[ { "from": "system", "value": "Undo temp change for standalone attr replacement\n" }, { "from": "human", "value": "<?php\n/**\n * Template for web-story post type.\n *\n * @package Google\\Web_Stories\n * @copyright 2020 Google LLC\n * @license https://www.apache.org/licenses/LICENSE-2.0 Apac...
php
chosen
[ { "from": "system", "value": "Check to see if the calendar type parameter is actually an existing class before adding it to the calendar factory.\n" }, { "from": "human", "value": "<?php\n\nnamespace Plummer\\Calendarful\\Calendar;\n\nclass CalendarFactory implements CalendarFactoryInterface\n{\...
php
chosen
[ { "from": "system", "value": "Feature: Add events to the console dispatcher\n\nFormer-commit-id: 3089f2463ddacbcaf7ac4572f91c1a48b168f887\nFormer-commit-id: 6e8a0c48d4897a8fa5ee16a8fe82be4aa216ae7c" }, { "from": "human", "value": "<?php\n$DIR_BASE_CORE = dirname(__DIR__);\ndefine('DIR_BASE', dir...
php
chosen