conversations
listlengths
2
3
source
stringclasses
1 value
stack
stringclasses
1 value
[ { "from": "system", "value": "Change $userAgent parameter from null to empty string" }, { "from": "human", "value": "<?php\n\nnamespace PragmaRX\\Tracker\\Support;\n\nuse UAParser\\Parser;\n\nclass UserAgentParser\n{\n public $parser;\n\n public $userAgent;\n\n public $operatingSystem;\...
php
chosen
[ { "from": "system", "value": "Index aggregated task data using permutation hash\n" }, { "from": "human", "value": "<?php\n/*\n This file contains a set of functions that are common to all\n tools of besearcher.\n\n Author: Fernando Bevilacqua <fernando.bevilacqua@his.se>\n */\n\nfunction aggreda...
php
chosen
[ { "from": "system", "value": "Add getRouteParam() method to controller\n" }, { "from": "human", "value": "<?php\n\n/*\n * This file is part of the Active Collab Bootstrap project.\n *\n * (c) A51 doo <info@activecollab.com>. All rights reserved.\n */\n\nnamespace ActiveCollab\\Bootstrap\\Control...
php
chosen
[ { "from": "system", "value": "Allow Conpherence room images up to 200px\n\nSummary: Provide higher resolution for Conpherence room images. Fixes T11728\n\nTest Plan:\nUpload a new photo, see it pulls in 200px image as background.\n\n{F1858660}\n\nReviewers: epriestley\n\nReviewed By: epriestley\n\nSubscribe...
php
chosen
[ { "from": "system", "value": "Add env for charset and prefix on config file.\n" }, { "from": "human", "value": "<?php\n\nreturn [\n 'oracle' => [\n 'driver' => 'oracle',\n 'tns' => env('DB_TNS', ''),\n 'host' => env('DB_HOST', ''),\n 'port' => env('D...
php
chosen
[ { "from": "system", "value": "Add CWD to config search path\n" }, { "from": "human", "value": "<?php\nuse Symfony\\Component\\DependencyInjection\\ContainerBuilder;\nuse Inanimatt\\SiteBuilder\\TransformerCompilerPass;\nuse Symfony\\Component\\Config\\FileLocator;\nuse Symfony\\Component\\Config...
php
chosen
[ { "from": "system", "value": "Implement simpler breadcrumbs for screens < 768px\n" }, { "from": "human", "value": "@if (isset($breadcrumbs))\n\t<ul class=\"breadcrumb hidden-xs\">\n\t\t@foreach ($breadcrumbs as $breadcrumb)\n\t\t\t<li>\n\t\t\t\t<a href=\"{{ $breadcrumb['link'] }}\">\n\t\t\t\t\t{...
php
chosen
[ { "from": "system", "value": "Add viaRemember to authenticator contract.\n" }, { "from": "human", "value": "<?php namespace Illuminate\\Contracts\\Auth;\n\ninterface Authenticator {\n\n\t/**\n\t * Determine if the current user is authenticated.\n\t *\n\t * @return bool\n\t */\n\tpublic function ...
php
chosen
[ { "from": "system", "value": "Check empty image + missing alt attribute.\n" }, { "from": "human", "value": "<li class=\"news-list-item\">\n <a class=\"news-list-item-link\" href=\"{{ $news->uri() }}\">\n <img class=\"news-list-item-image\" src=\"{{ $news->present()->image(540, 400) }}\...
php
chosen
[ { "from": "system", "value": "Add missing application configuration setting in the bundle extension\n" }, { "from": "human", "value": "<?php\n\nnamespace LAG\\AdminBundle\\DependencyInjection;\n\nuse Symfony\\Component\\Config\\FileLocator;\nuse Symfony\\Component\\DependencyInjection\\Container...
php
chosen
[ { "from": "system", "value": "Fix database table index name of cronjob logs\n" }, { "from": "human", "value": "<?php\nnamespace wcf\\data\\cronjob\\log;\nuse wcf\\data\\DatabaseObject;\n\n/**\n * Represents a croniob log.\n * \n * @author\tAlexander Ebert\n * @copyright\t2001-2016 WoltLab GmbH\n...
php
chosen
[ { "from": "system", "value": "Fix PositionAndLookPacket from not reading double\n" }, { "from": "human", "value": "<?php\n\nnamespace HHVMCraft\\Core\\Networking\\Packets;\n\nrequire \"HHVMCraft.Core/Helpers/HexDump.php\";\nuse HHVMCraft\\Core\\Helpers\\Hex;\n\nclass PlayerPositionAndLookPacket ...
php
chosen
[ { "from": "system", "value": "Fix a spelling error in the old behat1 machinist steps\n" }, { "from": "human", "value": "<?php\n$steps->Given('/^the following (\\w+) exists:$/', function($world, $blueprint, $table) {\n\t\\machinist\\behat\\functions\\createMachinesFromTable($world, $blueprint, $t...
php
chosen
[ { "from": "system", "value": "Resolve the dependency lazily to avoid resolving the UrlGenerator (and all Puli) when not used\n\nThe container is injected but it's fine because the Twig extension is a glue class…\n" }, { "from": "human", "value": "<?php\n\nnamespace Stratify\\TwigModule\\Extensio...
php
chosen
[ { "from": "system", "value": "Fix Null Id, on create user Postgresql\n" }, { "from": "human", "value": "<?php\n\nnamespace ZfcUser\\Mapper;\n\nuse Zend\\Stdlib\\Hydrator\\ClassMethods;\nuse ZfcUser\\Entity\\UserInterface as UserEntityInterface;\n\nclass UserHydrator extends ClassMethods\n{\n ...
php
chosen
[ { "from": "system", "value": "Use assert to typecheck options param\n" }, { "from": "human", "value": "<?php\n\nnamespace SearchApi\\Builders;\n\nuse SearchApi\\Builders\\QueryBuilder;\n\n/**\n * Responsible for building a query string for SolrSearch\n */\nclass SolrQueryBuilder implements Query...
php
chosen
[ { "from": "system", "value": "Update to use zara4.com instead of dev.zara4.com\n" }, { "from": "human", "value": "<?php namespace Zara4\\API\\Communication;\n\n\nuse GuzzleHttp\\Client;\nuse GuzzleHttp\\Exception\\RequestException;\n\nclass Util {\n\n const BASE_URL = \"http://dev.zara4.com\";\...
php
chosen
[ { "from": "system", "value": "Return types in manager tests\n" }, { "from": "human", "value": "<?php\n/*\n * WellCommerce Open-Source E-Commerce Platform\n * \n * This file is part of the WellCommerce package.\n *\n * (c) Adam Piotrowski <adam@wellcommerce.org>\n * \n * For the full copyright an...
php
chosen
[ { "from": "system", "value": "Update tests to include PHP 5.5 style Class::class calls\n" }, { "from": "human", "value": "<?php\n\nnamespace Chrisgeary92\\Pagespeed\\Test;\n\nuse Chrisgeary92\\Pagespeed\\Service;\n\nclass ServiceTest extends \\PHPUnit_Framework_TestCase\n{\n /** @test */\n ...
php
chosen
[ { "from": "system", "value": "Set default value of order in Quotation\n" }, { "from": "human", "value": "<?php\n\nuse Illuminate\\Support\\Facades\\Schema;\nuse Illuminate\\Database\\Schema\\Blueprint;\nuse Illuminate\\Database\\Migrations\\Migration;\n\nclass CreateQuotationsTable extends Migra...
php
chosen
[ { "from": "system", "value": "Set a CSP to upgrade all insecure requests\n\nBy setting a Content Security Policy, all HTTP requests will be now upgraded by\nsupported browsers to HTTPS automatically. This will ensure a secure-only\nexperience.\n" }, { "from": "human", "value": "<?php\n\n/* Redir...
php
chosen
[ { "from": "system", "value": "[DebugBundle][VarDumper] Fix server dumper placeholder command\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, plea...
php
chosen
[ { "from": "system", "value": "Add missing dependency for backend\n" }, { "from": "human", "value": "<?php\nclass Kwc_Advanced_GoogleMap_Component extends Kwc_Advanced_GoogleMapView_Component\n{\n public static function getSettings()\n {\n $ret = array_merge(parent::getSettings(), ar...
php
chosen
[ { "from": "system", "value": "Fix tree builder without a root node deprecation in Symfony/Config 4.2+\n" }, { "from": "human", "value": "<?php\n\nnamespace BW\\ActiveMenuItemBundle\\DependencyInjection;\n\nuse Symfony\\Component\\Config\\Definition\\Builder\\TreeBuilder;\nuse Symfony\\Component\...
php
chosen
[ { "from": "system", "value": "Return a 404 if there is no post with the provided ID\n" }, { "from": "human", "value": "<?php\n\nnamespace SymfonyDay\\Bundle\\BlogBundle\\Controller;\n\nuse Symfony\\Component\\HttpFoundation\\Response;\nuse Symfony\\Bundle\\FrameworkBundle\\Controller\\Controller...
php
chosen
[ { "from": "system", "value": "Add crud for folder in navigation\n" }, { "from": "human", "value": "<?php\n\nnamespace PHPOrchestra\\ModelBundle\\Document;\n\nuse Doctrine\\Common\\Collections\\ArrayCollection;\nuse Doctrine\\ODM\\MongoDB\\Mapping\\Annotations as ODM;\nuse Doctrine\\Common\\Colle...
php
chosen
[ { "from": "system", "value": "Stop checking if name is jude\n" }, { "from": "human", "value": "<?php\n\nnamespace Jmlamo\\DemoBundle\\Controller;\n\nuse Symfony\\Bundle\\FrameworkBundle\\Controller\\Controller;\nuse Sensio\\Bundle\\FrameworkExtraBundle\\Configuration\\Route;\nuse Sensio\\Bundle\...
php
chosen
[ { "from": "system", "value": "Add missing fields in the create game resource.\n" }, { "from": "human", "value": "@extends('layouts.app')\n\n@section('content')\n <form class=\"ui form\" action=\"{{ route('games.store') }}\" method=\"POST\">\n {{ csrf_field() }}\n\n <div class=\"...
php
chosen
[ { "from": "system", "value": "Check for deleted machine when showing pending surveys.\n\nHopefully a work around for #382\n" }, { "from": "human", "value": "<h2><span class=\"label label-default\">Pending surveys</span></h2>\n<table class=\"table table-striped table-hover\">\n\t<thead>\n\t\t<tr>...
php
chosen
[ { "from": "system", "value": "Fix bug with appending new attributes\n" }, { "from": "human", "value": "<?php\n\nnamespace MageTest\\Manager\\Attributes\\Provider;\n\n\n/**\n * Trait OverrideAttributes\n *\n * @package spec\\MageTest\\Manager\\Attributes\\Provider\n */\ntrait OverrideAttributes\n...
php
chosen
[ { "from": "system", "value": "Modify org name and address\n" }, { "from": "human", "value": "<div class=\"container-fluid\">\n <div class=\"container\">\n <div class=\"text-center\">\n <a href=\"https://www.youtube.com/channel/UCgMAAachC-yG8p8r06S938A\"><i class=\"fa fa-youtube fa...
php
chosen
[ { "from": "system", "value": "Change to navbar-default instead of inverse to allow easier style overrides.\n" }, { "from": "human", "value": "<nav class=\"navbar navbar-toggleable-md navbar-inverse fixed-top bg-inverse\">\n <button class=\"navbar-toggler navbar-toggler-right\" type=\"button\"...
php
chosen
[ { "from": "system", "value": "Allow determining allowed payment methods without having a current quote\n" }, { "from": "human", "value": "<?php\n/**\n * Quafzi_CustomerPaymentFilter_Model_Observer\n *\n * @category Payment\n * @package Quafzi_CustomerPaymentFilter\n * @author Thomas ...
php
chosen
[ { "from": "system", "value": "Adjust /admin panel to changes in module manager class.\n" }, { "from": "human", "value": "<?php\n\n/**\n * Description of ModuleLoader\n *\n * @author Adam Bukowski <abukowski@telaxus.com>\n */\nclass ModuleLoader {\n const all_modules = ':all:';\n\n private ...
php
chosen
[ { "from": "system", "value": "Fix problem with exception classes\n" }, { "from": "human", "value": "<?php\nnamespace SBLayout\\Model\\Page;\nuse SBLayout\\Model\\Application;\nuse SBLayout\\Model\\Page\\Content\\Contents;\n\n/**\n * Defines a page displaying arbitrary contents in one or more con...
php
chosen
[ { "from": "system", "value": "Add additional log statements when running cronjob\n" }, { "from": "human", "value": "<?php namespace GW2Heroes\\Console;\n\nuse GW2Heroes\\Updater\\Items\\ItemUpdater;\nuse GW2Heroes\\Updater\\Specializations\\SpecializationUpdater;\nuse GW2Heroes\\Updater\\Traits\...
php
chosen
[ { "from": "system", "value": "Add my email to the submit php form\n" }, { "from": "human", "value": "<?php\n\n$EmailFrom = \"\";\n$EmailTo = \"kimmarieallen@gmail.com\";\n$Subject = \"subject of message here\";\n$Name = Trim(stripslashes($_POST['Name'])); \n$Tel = Trim(stripslashes($_POST['Tel']...
php
chosen
[ { "from": "system", "value": "Use HTTPS for default resource icon\n" }, { "from": "human", "value": "<?php\nrequire_once(__DIR__ . \"/inc/header.php\");\n\n$db = get_database();\n$sql = \"SELECT\n `name`, `url`, `image_url`\n FROM\n `Resource`\";\n$resource_result = ...
php
chosen
[ { "from": "system", "value": "Use addData() to append the app object to the plates engine\n" }, { "from": "human", "value": "<?php\n\nnamespace Rych\\Silex\\Provider;\n\nuse Silex\\Application;\nuse Silex\\ServiceProviderInterface;\nuse Rych\\Plates\\Extension\\RoutingExtension;\nuse Rych\\Plate...
php
chosen
[ { "from": "system", "value": "Remove unused use statement from test.\n" }, { "from": "human", "value": "<?php\r\n\r\nnamespace Tests\\MoFlashCards\\ResourceBundle\\Service;\r\n\r\nuse MoFlashCards\\ResourceBundle\\Service\\TextToSpeechService;\r\nuse Symfony\\Bundle\\FrameworkBundle\\Test\\Kerne...
php
chosen
[ { "from": "system", "value": "Add register test to hashids test\n" }, { "from": "human", "value": "<?php\n\nnamespace Xu\\Tests\\Components;\n\nuse xu;\n\nclass Hashids_Test extends \\WP_UnitTestCase {\n\n public function test_encode() {\n $hashids = xu( 'hashids' );\n $this->as...
php
chosen
[ { "from": "system", "value": "Add the quick shortcut to create an image macro. Maybe.\n\nI don't actually have Phabricator installed locally so I have no idea if this works, but in theory this should add one of the + buttons in the left sidebar to quickly add a new macro." }, { "from": "human", ...
php
chosen
[ { "from": "system", "value": "FIX Exceptions broken if no notifiers specified\n" }, { "from": "human", "value": "<?php\r\n\r\nclass HailApiException extends Exception {\r\n\r\n\t/**\r\n\t * A class list of notifiers to use. Must implement HailNotifier\r\n\t * @see HailNotifier\r\n\t * @var array...
php
chosen
[ { "from": "system", "value": "Test for setOption in AdapterAbstract\n" }, { "from": "human", "value": "<?php\n\nnamespace Versionable\\Tests\\Prospect\\Adapter;\n\nuse Versionable\\Prospect\\Adapter\\AdapterAbstract;\n\n/**\n * Test class for AdapterAbstract.\n * Generated by PHPUnit on 2011-04-...
php
chosen
[ { "from": "system", "value": "Add started by field in thread listing\n" }, { "from": "human", "value": "<div class=\"listing-entry\">\n <img src=\"{{ theme_asset('img/unread.png') }}\" alt=\"\" class=\"listing-forum-hasread\">\n <div>\n <div class=\"listing-entry-name\">\n ...
php
chosen
[ { "from": "system", "value": "Remove pre/post routing config for Expressive\n" }, { "from": "human", "value": "<?php\n\nreturn [\n // This can be used to seed pre- and/or post-routing middleware\n 'middleware_pipeline' => [\n // An array of middleware to register prior to registrati...
php
chosen
[ { "from": "system", "value": "Make the tree of classes.\n" }, { "from": "human", "value": "<?php\n\nnamespace App\\Http\\Controllers;\n\nuse DB;\nuse App\\Http\\Requests;\nuse Illuminate\\Http\\Request;\n\nclass HomeController extends Controller\n{\n /**\n * Create a new controller instan...
php
chosen
[ { "from": "system", "value": "refactor(assignments): Create relationship for assignments table\n\nmodifield: app/Assignment.php\n\nsee #107\n" }, { "from": "human", "value": "<?php\n\nnamespace App;\n\nuse Illuminate\\Database\\Eloquent\\Model;\n\nclass Assignment extends Model\n{\n protect...
php
chosen
[ { "from": "system", "value": "Add response to forgot endpoint\n" }, { "from": "human", "value": "<?php\n/**\n * Copyright (c) 2016 Manuel Lopez <manuel.lopez@stud.bbbaden.ch>\n *\n * This program is free software. It comes without any warranty, to\n * the extent permitted by applicable law. You ...
php
chosen
[ { "from": "system", "value": "Enable DI when create the preset providers\n" }, { "from": "human", "value": "<?php\n\nnamespace Concrete\\Core\\Area\\Layout\\Preset\\Provider;\n\nuse Concrete\\Core\\Foundation\\Service\\Provider as ServiceProvider;\nuse Concrete\\Core\\Application\\Application;\n...
php
chosen
[ { "from": "system", "value": "Fix admin settings with php7.1\n" }, { "from": "human", "value": "<?php\n\n/**\n * ownCloud - password\n *\n * This file is licensed under the Affero General Public License version 3 or\n * later. See the COPYING file.\n *\n * @author Patrick Paysant / CNRS <ppaysan...
php
chosen
[ { "from": "system", "value": "Reduce number of queries, include expiration date\n" }, { "from": "human", "value": "<?php\ninclude '../scat.php';\n\n$card= $db->escape($_REQUEST['card']);\n$card= preg_replace('/^RAW-/', '', $card);\n\n$q= \"SELECT id, active, CONCAT(id, pin) card\n FROM gif...
php
chosen
[ { "from": "system", "value": "Change add debit note to greedy credit note.\n" }, { "from": "human", "value": "<?php\n\nrequire __DIR__.'/autoload.php';\n\nuse LaravelLb\\LogicBoxesReseller;\n\n// Setup user id and api key\n$userId = getenv('LB_AUTH_USERID');\n$apiKey = getenv('LB_API_KEY');\n\n/...
php
chosen
[ { "from": "system", "value": "Fix a possible deadlock in unit tests after an error\n\nSummary:\nAfter certain types of errors, we may deadlock when trying to destroy test databases.\n\nSpecifically, we still have connections open to, say, `phabricator_unittest_abasonaknlbaklnasb_herald` (or whatever) and My...
php
chosen
[ { "from": "system", "value": "Update routes (and the names thereof)\n" }, { "from": "human", "value": "<?php\n\nRoute::get('/login', 'LoginController@index')->name('login.index');\nRoute::post('/login', 'LoginController@store')->name('login.store');\n\nRoute::get('/register', 'RegisterController...
php
chosen
[ { "from": "system", "value": "Add domain route list to support subdomain routes; fix bug with multiple params; add console error for missing params.\n" }, { "from": "human", "value": "<?php\n\nnamespace Tightenco\\Ziggy;\n\nuse Illuminate\\Routing\\Router;\n\nclass BladeRouteGenerator\n{\n pr...
php
chosen
[ { "from": "system", "value": "Fix code highlighting with no language or unknown language\n\n" }, { "from": "human", "value": "<?php\n\nnamespace allejo\\stakx\\Core;\n\nuse Highlight\\Highlighter;\n\nclass MarkdownEngine extends \\Parsedown\n{\n protected $highlighter;\n\n public function ...
php
chosen
[ { "from": "system", "value": "Fix for unknown references in older twig versions\n" }, { "from": "human", "value": "<?php\n\nnamespace Maba\\Bundle\\WebpackBundle\\ErrorHandler;\n\nuse Exception;\nuse Maba\\Bundle\\WebpackBundle\\Exception\\ResourceParsingException;\nuse Psr\\Log\\LoggerInterface...
php
chosen
[ { "from": "system", "value": "Add test to find a setting by name\n" }, { "from": "human", "value": "<?php namespace Modules\\Setting\\Tests;\n\nclass EloquentSettingRepositoryTest extends BaseSettingTest\n{\n public function setUp()\n {\n parent::setUp();\n }\n\n /** @test */\...
php
chosen
[ { "from": "system", "value": "Remove doctrine migration on plugin manager\n" }, { "from": "human", "value": "<?php\n/*\n * This file is part of the Maker plugin\n *\n * Copyright (C) 2016 LOCKON CO.,LTD. All Rights Reserved.\n *\n * For the full copyright and license information, please view the...
php
chosen
[ { "from": "system", "value": "FIX: Fix really stupid bug that meant images were not saved\n" }, { "from": "human", "value": "<?php\n/**\n* Defines the SupportingProjectPage page type - initial code created by ss generator\n*/\nclass PageWithImage extends Page implements RenderableAsPortlet {\n\n...
php
chosen
[ { "from": "system", "value": "Fix a few comments for wording.\n" }, { "from": "human", "value": "<?php namespace App\\Providers;\n\nuse Illuminate\\Routing\\Router;\nuse Illuminate\\Foundation\\Support\\Providers\\RouteServiceProvider as ServiceProvider;\n\nclass RouteServiceProvider extends Ser...
php
chosen
[ { "from": "system", "value": "Tag field can be null." }, { "from": "human", "value": "<?php\n\nuse Zablose\\Navbar\\NavbarEntityCore;\nuse Illuminate\\Support\\Facades\\Schema;\nuse Illuminate\\Database\\Schema\\Blueprint;\nuse Illuminate\\Database\\Migrations\\Migration;\n\nclass CreateNavbarsT...
php
chosen
[ { "from": "system", "value": "Add page_* prefix to values set in the PageInfo js\n" }, { "from": "human", "value": "<?php\n/**\n * @package Mautic\n * @copyright 2016 Mautic Contributors. All rights reserved.\n * @author Mautic\n * @link http://mautic.org\n * @license GNU/G...
php
chosen
[ { "from": "system", "value": "Make a unit test compatible with php 7.0\n" }, { "from": "human", "value": "<?php\n\ncall_user_func(function(int $x, string $y, stdClass $z, bool $w) {\n [$a] = $x;\n [$b] = $y;\n [$c] = $z;\n [$d] = $w;\n [$e] = null;\n return [$a, $b, $c, $d, $e]...
php
chosen
[ { "from": "system", "value": "Allow adding translations for console commands\n\nThis is the state when there is no request available\n" }, { "from": "human", "value": "<?php\n\nnamespace ForkCMS\\Core\\Domain\\Application;\n\nuse ForkCMS\\Modules\\Internationalisation\\Domain\\Translation\\Trans...
php
chosen
[ { "from": "system", "value": "Fix phones in update profile form\n" }, { "from": "human", "value": "<?php\n\nnamespace Furniture\\FrontendBundle\\Form\\Type\\UserProfile;\n\nuse Furniture\\RetailerBundle\\Entity\\RetailerUserProfile;\nuse Symfony\\Component\\Form\\AbstractType;\nuse Symfony\\Comp...
php
chosen
[ { "from": "system", "value": "BAP-2898: Add widgets to render lists of calls and emails on shopping cart and order page\n - small fix in email listener\n" }, { "from": "human", "value": "<?php\n\nnamespace Oro\\Bundle\\EmailBundle\\EventListener\\Datagrid;\n\nuse Oro\\Bundle\\DataGridBundle\\Dat...
php
chosen
[ { "from": "system", "value": "Fix in block for title - now relative url.\n" }, { "from": "human", "value": "<?php\n/**\n * @package\t\tTopLogo\n * @category\tblock\n * @author\t\tNazar Mokrynskyi <nazar@mokrynskyi.com>\n * @copyright\tCopyright (c) 2011-2013, Nazar Mokrynskyi\n * @license\t\tMIT...
php
chosen
[ { "from": "system", "value": "Add explicit default for edu_suitable_for_home\n" }, { "from": "human", "value": "<?php\n\nuse Illuminate\\Database\\Migrations\\Migration;\nuse Illuminate\\Database\\Schema\\Blueprint;\nuse Illuminate\\Support\\Facades\\Schema;\n\nclass AddEduAttributesToArticles e...
php
chosen
[ { "from": "system", "value": "Fix minor object parameter conflict with PHPUnit.\n" }, { "from": "human", "value": "<?php\n\nnamespace League\\Plates\\Template;\n\nclass DataTest extends \\PHPUnit_Framework_TestCase\n{\n private $data;\n\n public function setUp()\n {\n $this->data...
php
chosen
[ { "from": "system", "value": "Update converter to make the array always contain all fields. Populate with a default value if a value for that field does not exist in input data\n" }, { "from": "human", "value": "<?php\n\nnamespace Jh\\DataImportMagento\\ItemConverter;\n\nuse Ddeboer\\DataImport\...
php
chosen
[ { "from": "system", "value": "Add language switcher to guestarea & memberarea\n" }, { "from": "human", "value": "<?php\n\ndeclare(strict_types=1);\n\nuse Spatie\\Menu\\Laravel\\Link;\nuse Cortex\\Foundation\\Models\\Menu as MenuModel;\n\nif (config('cortex.foundation.route.locale_prefix')) {\n ...
php
chosen
[ { "from": "system", "value": ":lipstick: Move class brace on a new line\n" }, { "from": "human", "value": "<?php\n\nnamespace Estaty;\n\nuse Silex\\Application as SilexApplication;\n\nclass Application extends SilexApplication {\n\n use SilexApplication\\UrlGeneratorTrait;\n use SilexAppli...
php
chosen
[ { "from": "system", "value": "Fix wrong table preferrence for role_user\n" }, { "from": "human", "value": "<?php\n\n\nuse Illuminate\\Database\\Migrations\\Migration;\nuse Illuminate\\Database\\Schema\\Blueprint;\n\nclass CreateRoleUserTable extends Migration {\n\n /**\n * Run the migrati...
php
chosen
[ { "from": "system", "value": "Print stylesheet must be separate, and is not currently available anyway\n" }, { "from": "human", "value": "<?php\n/**\n * Groups configuration for default Minify implementation\n * @package Minify\n */\n\n/** \n * You may wish to use the Minify URI Builder app to s...
php
chosen
[ { "from": "system", "value": "Fix error in ticket category management page\n" }, { "from": "human", "value": "<?php \n\n // Set page title and set crumbs to index\n set_page_title(lang('categories'));\n project_tabbed_navigation(PROJECT_TAB_TICKETS);\n project_crumbs(array(\n array(lang('...
php
chosen
[ { "from": "system", "value": "Add the validation of setter methods\n" }, { "from": "human", "value": "<?php\n/**\n * 面向对象-属性设置器\n */\nclass Person\n{\n private $age;\n\n /**\n * Sets the value of age.\n *\n * @param mixed $age the age\n *\n * @return self\n */\n ...
php
chosen
[ { "from": "system", "value": "Fix undefined class Profile in templates\n" }, { "from": "human", "value": "<?php\n\n/*\n * This file is part of Twig.\n *\n * (c) Fabien Potencier\n *\n * For the full copyright and license information, please view the LICENSE\n * file that was distributed with thi...
php
chosen
[ { "from": "system", "value": "Change timestamp of failed attempts to UTC\n" }, { "from": "human", "value": "<?php\n\nnamespace app\\models;\n\nuse Yii;\nuse yii\\db\\ActiveRecord;\nuse yii\\db\\Expression;\nuse yii\\behaviors\\TimestampBehavior;\n\nclass FailedAttempt extends ActiveRecord {\n\n ...
php
chosen
[ { "from": "system", "value": "Use only POST for http-bind route\n" }, { "from": "human", "value": "<?php \n/**\n * ownCloud - JavaScript XMPP Chat\n *\n * Copyright (c) 2014 Klaus Herberth <klaus@jsxc.org> <br>\n * Released under the MIT license\n *\n * @author Klaus Herberth\n */\n\nuse \\OCA\\...
php
chosen
[ { "from": "system", "value": "Test default values are set on the built logger\n" }, { "from": "human", "value": "<?php\nnamespace Graze\\Monolog;\n\nuse Monolog\\Logger;\n\nclass LoggerBuilderIntegrationTest extends \\PHPUnit_Framework_TestCase\n{\n public function setUp()\n {\n $th...
php
chosen
[ { "from": "system", "value": "Check to make sure username and password are explicitly posted\n" }, { "from": "human", "value": "<?\nclass SessionsController extends ApplicationController{\n function login(){\n //Show Login Page\n\t}\n\n\tfunction process(){\n\t\t$this->auth->logUserIn($_POST...
php
chosen
[ { "from": "system", "value": "Add possitive user login test\n" }, { "from": "human", "value": "<?php\nrequire_once('Autoload.php');\nclass SQLAuthTest extends PHPUnit_Framework_TestCase\n{\n public function testSQLAuthenticator()\n {\n $GLOBALS['FLIPSIDE_SETTINGS_LOC'] = './tests/tr...
php
chosen
[ { "from": "system", "value": "Create new object of Post class" }, { "from": "human", "value": "<?php\n" }, { "from": "gpt", "value": "<?php\n\n$post = new Post();\n$post->heading = 'My first post';\n$post->content = 'The content of my first post...';\n\necho '<h1>' . $post->heading ....
php
chosen
[ { "from": "system", "value": "[GH-4213] Add deprecation to SchemaSynchronizer API.\n" }, { "from": "human", "value": "<?php\n\nnamespace Doctrine\\DBAL\\Schema\\Synchronizer;\n\nuse Doctrine\\DBAL\\Connection;\nuse Throwable;\n\n/**\n * Abstract schema synchronizer with methods for executing bat...
php
chosen
[ { "from": "system", "value": "Add directory to cookie clear/set in cookie middleware\n" }, { "from": "human", "value": "<?php\n\nnamespace Concrete\\Core\\Http\\Middleware;\n\nuse Concrete\\Core\\Cookie\\CookieJar;\nuse Symfony\\Component\\HttpFoundation\\Request;\nuse Symfony\\Component\\HttpFo...
php
chosen
[ { "from": "system", "value": "Add Subject and Keyword fields to PDF metadata\n" }, { "from": "human", "value": "<?php\n# THIS ONE DOES NOT HAVE AddPageByArray ANY MORE :-)\n\ninclude(\"../mpdf.php\");\n\n$html_data = file_get_contents(\"body.html\");\n$html = substr($html_data, 12, strlen($html_...
php
chosen
[ { "from": "system", "value": "Fix swiftmailer not using the correct transport\n" }, { "from": "human", "value": "<?php\n\nnamespace Common\\Mailer;\n\nuse PDOException;\nuse Symfony\\Component\\Console\\Event\\ConsoleCommandEvent;\nuse Symfony\\Component\\HttpKernel\\Event\\GetResponseEvent;\nus...
php
chosen
[ { "from": "system", "value": "Support all maintained Guzzle versions (v5 and v6)\n" }, { "from": "human", "value": "<?php\n\ndeclare(strict_types=1);\n\nnamespace Voronkovich\\SberbankAcquiring\\HttpClient;\n\nuse GuzzleHttp\\ClientInterface;\nuse Psr\\Http\\Message\\ResponseInterface;\n\n/**\n ...
php
chosen
[ { "from": "system", "value": "Return FALSE at end instead of the default NULL\n" }, { "from": "human", "value": "<?php\ninclude_once(\"NerdsvillePHPValidator.php\");\n\nclass NerdsvillePHPValidators_EmailValid implements NerdsvillePHPValidator {\n public function validate($subject) {\n ...
php
chosen
[ { "from": "system", "value": "Use correct key for retrieving redirection messages from the session.\n" }, { "from": "human", "value": "<?php\n\nnamespace FluxBB\\View;\n\nuse Illuminate\\Contracts\\View\\View;\nuse Symfony\\Component\\HttpFoundation\\Session\\SessionInterface;\n\nclass AlertsCom...
php
chosen
[ { "from": "system", "value": "Make the profile link inactive when needed.\n" }, { "from": "human", "value": "<!DOCTYPE html>\n<html>\n <head>\n <meta charset=\"utf-8\">\n <title>{{ trans('messages.project-name') }}</title>\n <style>\n body {\n pa...
php
chosen
[ { "from": "system", "value": "Add the \"teeny\" wp editor option key\n" }, { "from": "human", "value": "<?php\n\nnamespace jvwp\\components;\n\nuse fieldwork\\components\\Textarea;\n\n/**\n * Fieldwork Field implementation of the wp_editor function\n */\nclass WpEditorField extends Textarea\n{\n...
php
chosen
[ { "from": "system", "value": "Call method for creating configurator\n\nConfigurator will be available in request object\n" }, { "from": "human", "value": "<?php\nnamespace MicroFW\\Core;\n\nuse MicroFW\\Http\\Request, MicroFW\\Http\\Response;\n\nclass Application\n{\n /**\n * Start and se...
php
chosen
[ { "from": "system", "value": "Fix documentation and variable names.\n\n\nsvn commit r29747\n" }, { "from": "human", "value": "<?php\n\n/* vim: set noexpandtab tabstop=4 shiftwidth=4 foldmethod=marker: */\n\nrequire_once 'Swat/SwatFrame.php';\nrequire_once 'Swat/SwatReplicableContainer.php';\n\n/...
php
chosen
[ { "from": "system", "value": "Fix require path to i18n\n" }, { "from": "human", "value": "<?php\n\n// Setup I18N\nrequire_once \"../src/Core/I18N.php\";\nrequire_once \"setup_i18n.php\";" }, { "from": "gpt", "value": "<?php\n\n// Setup I18N before autoload to prevent Laravel helpers ...
php
chosen
[ { "from": "system", "value": "Fix for default index, this shouldn't be the pages overview\n" }, { "from": "human", "value": "<?php\n\nnamespace Kunstmaan\\AdminBundle\\Controller;\n\nuse Sensio\\Bundle\\FrameworkExtraBundle\\Configuration\\Route;\nuse Sensio\\Bundle\\FrameworkExtraBundle\\Config...
php
chosen
[ { "from": "system", "value": "Load theme.js in module assets\n" }, { "from": "human", "value": "<?php if (isset($this->params['css']) && ($this->params['css'] !== false)): ?>\n[?php use_stylesheet('<?php echo $this->params['css'] ?>', 'first') ?]\n<?php endif; ?>\n" }, { "from": "gpt", ...
php
chosen
[ { "from": "system", "value": "Add a comfirmation on the auto publish action\n" }, { "from": "human", "value": "<?php\n\nnamespace Liip\\RD\\Action;\n\nclass VcsPublishAction extends BaseAction\n{\n public function execute($context)\n {\n $context->getService('vcs')->publishTag(\n ...
php
chosen