conversations
listlengths
2
3
source
stringclasses
1 value
stack
stringclasses
1 value
[ { "from": "system", "value": "Add 2 methods to access logs\n" }, { "from": "human", "value": "<?php\n\nnamespace PhpTabs\\Component;\n\n\nabstract class Log\n{\n /**\n * @var array config options\n */\n private static $data = array();\n\n\n /**\n * Add a log event\n * \n * @param st...
php
chosen
[ { "from": "system", "value": "Set http headers from laravel request\n\nsets the http headers on mobile detect from the laravel request headers,\nso headers wont be taken directly from global $_SERVER.\n" }, { "from": "human", "value": "<?php namespace Jenssegers\\Agent;\n\nuse Illuminate\\Suppor...
php
chosen
[ { "from": "system", "value": "Feature: Update request logger middleware implementation\n" }, { "from": "human", "value": "<?php\n\nnamespace PhalconUtils\\Middleware;\n\nuse Phalcon\\Mvc\\Micro;\nuse PhalconUtils\\Constants\\Services;\nuse PhalconUtils\\Util\\Logger;\n\n/**\n * Class LoggerMiddl...
php
chosen
[ { "from": "system", "value": "Allow phone numbers from 8 to 12 digits instead of fixed 11" }, { "from": "human", "value": "<?php\n\nnamespace Difra\\Security\\Filter;\n\nclass Phone implements Common\n{\n /**\n * Validate input string\n * @param string $string\n * @return bool\n ...
php
chosen
[ { "from": "system", "value": "Make checks for requested directory\n" }, { "from": "human", "value": "<?php\n/**\n * TODO: Docs\n *\n * PHP.Gt (http://php.gt)\n * @copyright Copyright Ⓒ 2014 Bright Flair Ltd. (http://brightflair.com)\n * @license Apache Version 2.0, January 2004. http://www.apach...
php
chosen
[ { "from": "system", "value": "Fix migration so you can rollback.\n" }, { "from": "human", "value": "<?php\n\nuse Illuminate\\Database\\Migrations\\Migration;\nuse Illuminate\\Database\\Schema\\Blueprint;\n\nclass UpdateTagsTable extends Migration {\n\n\tpublic function up()\n\t{\n\n\t\tSchema::t...
php
chosen
[ { "from": "system", "value": "Fix instructions for writing a check" }, { "from": "human", "value": "@component('mail::message')\n\n# You're almost done!\n\nWe've received your RoboJackets dues form!\n\nNext, you need to make a payment for **${{$duesPackage->cost}}**.\n\nWhen completing the form,...
php
chosen
[ { "from": "system", "value": "Use YesWikiHandler instead of YesWikiAction\n" }, { "from": "human", "value": "<?php\n\nuse YesWiki\\Core\\YesWikiAction;\n\nclass HelloHandler extends YesWikiAction \n{\n function run($arguments) \n {\n $pageBody = $this->wiki->page['body'];\n r...
php
chosen
[ { "from": "system", "value": "Remove superfluous shell executable definition. Stop Vue being set as\nthe default frontend.\n" }, { "from": "human", "value": "<?php\n\nnamespace App\\Actions;\n\nuse Facades\\App\\LamboConfig;\n\nclass EditConfig\n{\n public function __invoke()\n {\n ...
php
chosen
[ { "from": "system", "value": "Add typehints to the database data collector class\n" }, { "from": "human", "value": "<?php\n\nnamespace Common\\DataCollector;\n\nuse Symfony\\Component\\HttpKernel\\DataCollector\\DataCollector;\nuse Symfony\\Component\\HttpFoundation\\Request;\nuse Symfony\\Compo...
php
chosen
[ { "from": "system", "value": "Add the right use clause.\n" }, { "from": "human", "value": "<?php\nnamespace Datenknoten\\LigiBundle\\Form\\Type;\n\nuse Symfony\\Component\\Form\\AbstractType;\nuse Symfony\\Component\\Form\\FormInterface;\nuse Symfony\\Component\\Form\\FormView;\nuse Symfony\\Com...
php
chosen
[ { "from": "system", "value": "Add `null` in typehint where needed.\n" }, { "from": "human", "value": "<?php\n/**\n * Bright Nucleus View Component.\n *\n * @package BrightNucleus\\View\n * @author Alain Schlesser <alain.schlesser@gmail.com>\n * @license MIT\n * @link http://www.brigh...
php
chosen
[ { "from": "system", "value": "Add proper group picing in the new/edit form.\n" }, { "from": "human", "value": "<?php\n\nnamespace BisonLab\\SakonninBundle\\Form;\n\nuse Symfony\\Component\\Form\\AbstractType;\nuse Symfony\\Component\\Form\\FormBuilderInterface;\nuse Symfony\\Component\\OptionsRe...
php
chosen
[ { "from": "system", "value": "Use PingFactory and mock ping process\n" }, { "from": "human", "value": "<?php\nnamespace Loct\\Pinger\\Command;\n\nuse \\Symfony\\Component\\Console\\Application;\nuse \\Symfony\\Component\\Console\\Tester\\CommandTester;\nuse \\PHPUnit_Framework_TestCase;\n\nclass...
php
chosen
[ { "from": "system", "value": "Introduce ObjectDocument for serving API requests\n" }, { "from": "human", "value": "<?php\nnamespace Gt\\WebEngine\\Logic;\n\nabstract class Api extends AbstractLogic {\n\tprotected $object;\n\n\t/** @noinspection PhpMissingParentConstructorInspection */\n\tpublic ...
php
chosen
[ { "from": "system", "value": "Fix missing type in array hydrator\n" }, { "from": "human", "value": "<?php\n/* \n * Copyright 2014 Jack Sleight <http://jacksleight.com/>\n * This source file is subject to the MIT license that is bundled with this package in the file LICENCE. \n */\n\nnamespace Co...
php
chosen
[ { "from": "system", "value": "Add providers application form woo\n" }, { "from": "human", "value": "<div class=\"page-header\">\n <h1>Apply to be a listed Provider</h1>\n</div>\n<div class=\"row providers\">\n <div class=\"span12\">\n <p>To apply to be listed on the <a href=\"/provi...
php
chosen
[ { "from": "system", "value": "Fix pusher dispatcher return value as boolean\n" }, { "from": "human", "value": "<?php\n\nnamespace IrishDan\\NotificationBundle\\Dispatcher;\n\nuse IrishDan\\NotificationBundle\\Message\\MessageInterface;\nuse IrishDan\\NotificationBundle\\PusherManager;\n\nclass P...
php
chosen
[ { "from": "system", "value": "Handle exception in test site\n" }, { "from": "human", "value": "<?php # -*- coding: utf-8 -*-\ndeclare(strict_types=1);\n\nrequire_once '../vendor/autoload.php';\nuse Bueltge\\Marksimple\\Marksimple;\n\nrequire_once 'head.php';\n?>\n\n<div class=\"main\">\n <art...
php
chosen
[ { "from": "system", "value": "Add \"test\" disposition to doc\n" }, { "from": "human", "value": "<?php\n\ndeclare(strict_types=1);\n\nnamespace MaxMind\\MinFraud\\Model;\n\n/**\n * Model with the disposition set by custom rules.\n *\n * In order to receive a disposition, you must be using minFra...
php
chosen
[ { "from": "system", "value": "Fix tests for legacy phpunit versions\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 LICENSE\n *...
php
chosen
[ { "from": "system", "value": "Update tests for actual tables" }, { "from": "human", "value": "<?php namespace CodeIgniter\\Database\\Live;\n\nuse CodeIgniter\\Test\\CIDatabaseTestCase;\n\n/**\n * @group DatabaseLive\n */\nclass MetadataTest extends CIDatabaseTestCase\n{\n\tprotected $refresh = t...
php
chosen
[ { "from": "system", "value": "Fix moment provider using compiled date instead of actual" }, { "from": "human", "value": "<?php declare(strict_types=1);\n\nnamespace SeStep\\Moment;\n\nuse Nette\\DI\\CompilerExtension;\nuse Nette\\DI\\ServiceDefinition;\n\nclass MomentProviderExtension extends Co...
php
chosen
[ { "from": "system", "value": "Change mecanism to retrive LAN IP" }, { "from": "human", "value": "<?php\n\nfunction getLanIpAddr() {\n $lanIpAddr = null;\n exec(\"ifconfig en1 inet\", $output);\n\n foreach ($output as $value) {\n if (strpos($value, 'inet') !== false) {\n preg_match('/[...
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": "Fix warnings from phpunit about deprecated assertType\n" }, { "from": "human", "value": "<?php\nnamespace VXML;\n\nclass EventTest extends \\PHPUnit_Framework_TestCase {\n\t\n\t/**\n\t * @var VXML\\Event\n\t */\n\tprivate $event;\n\t\n\t/**\n\t * @var VXML\\Rule\\Ru...
php
chosen
[ { "from": "system", "value": "Fix secret:generate command to simply generate random 32-char length string\n" }, { "from": "human", "value": "<?php\n/**\n * This file is part of the PHPLucidFrame library.\n * The script executes the command `php lucidframe secret:generate [options]`\n *\n * @pack...
php
chosen
[ { "from": "system", "value": "Update Tapastic plugin for 1.7.9 compatibility\n" }, { "from": "human", "value": "<?php\nclass Af_Tapastic extends Plugin {\n\n function about() {\n return array(0.1, \"Fetch image from comics hosted at tapastic.com\", \"Markus Wiik\");\n }\n\n funct...
php
chosen
[ { "from": "system", "value": "Revert \"We shouldn’t clear history, since we’re starting a new history file.\"\n\nYeah. That was a brain fart. We absolutely should.\n\nThis reverts commit 939eec2127dd22534ccabc81d9411ad870176c4e.\n" }, { "from": "human", "value": "<?php\n\n/*\n * This file is par...
php
chosen
[ { "from": "system", "value": "Test properties are set on Settings object.\n" }, { "from": "human", "value": "<?php\nnamespace Gt\\Database\\Connection;\n\nclass SettingsTest extends \\PHPUnit_Framework_TestCase {\n\n}#" }, { "from": "gpt", "value": "<?php\nnamespace Gt\\Database\\Con...
php
chosen
[ { "from": "system", "value": "Add eZ repository to the migration's attribute\n\nAs the repository will most likely be used most of the time, it is set as a shortcut attribute before up and down migrations.\n" }, { "from": "human", "value": "<?php\n/**\n* This file is part of the kreait eZ Publis...
php
chosen
[ { "from": "system", "value": "Enable the write of the offical README.md\n" }, { "from": "human", "value": "#! /bin/env php\n<?php\n\n// Load readme.md template\n$readme = file_get_contents(__DIR__ . '/README.md');\n\n// Creating simple tags\n$readme = fillReadme($readme, 'creating-simple-tags');...
php
chosen
[ { "from": "system", "value": "Add a bunch of things for ContentItem support\n" }, { "from": "human", "value": "<?php\n\n$REGISTER_LTI2 = array(\n\"name\" => \"Quizzes\",\n\"FontAwesome\" => \"fa-question-circle\",\n\"short_name\" => \"Quizzes\",\n\"description\" => \"This tool provides a quiz en...
php
chosen
[ { "from": "system", "value": "Change db user to 'chopin'\n" }, { "from": "human", "value": "<?php\n\nreturn [\n 'class' => 'yii\\db\\Connection',\n 'dsn' => 'mysql:host=localhost;dbname=chopin_development',\n 'username' => 'root',\n 'password' => '',\n 'charset' => 'utf8',\n];\n" }, { ...
php
chosen
[ { "from": "system", "value": "Remove slashes from school name incase there are quotes or\napostrophes in a school name.\n" }, { "from": "human", "value": "<?php\n\nrequire_once LIBDIR . '/testCourses.php';\nrequire_once \"stellar_lib.inc\";\n\n$selected_school_name = $_REQUEST['which'];\n\n$scho...
php
chosen
[ { "from": "system", "value": "Update navigation to use Orchestra\\Decorator::navbar()\n\nSigned-off-by: crynobone <e1a543840a942eb68427510a8a483282a7bfeddf@gmail.com>\n" }, { "from": "human", "value": "<div class=\"navbar\">\n <div class=\"navbar-inner\">\n\n \t\t<button type=\"button\" class=...
php
chosen
[ { "from": "system", "value": "Remove table var from role\n" }, { "from": "human", "value": "<?php namespace JWS\\UserSuite;\n\nuse Illuminate\\Database\\Eloquent\\Model;\n\nclass Role extends Model\n{\n\n //private $usersuite = config('usersuite').'role';\n\n protected $table = config('us...
php
chosen
[ { "from": "system", "value": "Document what the new option does\n" }, { "from": "human", "value": "<?php\n\nnamespace Backend\\Form\\Type;\n\nuse Backend\\Core\\Engine\\Model;\nuse Symfony\\Component\\Form\\AbstractType;\nuse Symfony\\Component\\Form\\Extension\\Core\\Type\\HiddenType;\nuse Symf...
php
chosen
[ { "from": "system", "value": "Test - array after reset() stays the same\n" }, { "from": "human", "value": "<?php\n\n/** @var float $float */\n$float = doFoo();\n\n/** @var int $integer */\n$integer = doFoo();\n\n$string = 'foo';\n\n/** @var string|null $stringOrNull */\n$stringOrNull = doFoo();\...
php
chosen
[ { "from": "system", "value": "Fix autoload path for dep-installations" }, { "from": "human", "value": "<?php\nnamespace Crunch\\CacheControl;\n\nrequire __DIR__ . '/../vendor/autoload.php';\n\n$console = new Console\\Application;\n\n$console->run();\n" }, { "from": "gpt", "value": "<...
php
chosen
[ { "from": "system", "value": "Remove altruja script from page.\n" }, { "from": "human", "value": "<?php get_template_part('templates/head'); ?>\n<body <?php body_class(); ?>>\n<!--<script src=\"https://www.altruja.de/i/lcov\"></script><span id=\"ef-bl-x7jn2nd9j\">Ein <a href=\"http://www.altruja...
php
chosen
[ { "from": "system", "value": "Create backtrace log file instead of dumping backtrace\n" }, { "from": "human", "value": "<?php\n/**\n * Part of Cli for CodeIgniter\n *\n * @author Kenji Suzuki <https://github.com/kenjis>\n * @license MIT License\n * @copyright 2015 Kenji Suzuki\n * @link ...
php
chosen
[ { "from": "system", "value": "Add short description for front page\n" }, { "from": "human", "value": "<?php\n/**\n * @package air\n */\n\nget_header(); ?>\n\n\t<div id=\"primary\" class=\"content-area\">\n\t\t<main id=\"main\" class=\"site-main\">\n\n\t\t\t<?php\n\t\t\twhile ( have_posts() ) : t...
php
chosen
[ { "from": "system", "value": "Change urls for scripts and css for webpack\n" }, { "from": "human", "value": "<?php \ndefine('ENVIRONMENT_DEVELOPMENT', 0);\ndefine('ENVIRONMENT_HNEWS_CO', 2);\n\ndefine('ROOT_PATH', dirname(__FILE__, 2).'/');\ndefine('INC_PATH', ROOT_PATH.'inc/');\ndefine('VIEWS_P...
php
chosen
[ { "from": "system", "value": "Update Version + Changelog URL\n" }, { "from": "human", "value": "<?php\n\nuse app\\models\\settings\\AntragsgruenApp;\n\n/**\n * @var AntragsgruenApp $params\n */\n\ndefine('ANTRAGSGRUEN_VERSION', '3.1.0');\ndefine('ANTRAGSGRUEN_HISTORY_URL', 'https://github.com/Ca...
php
chosen
[ { "from": "system", "value": "Fix admin page permitted user logic\n" }, { "from": "human", "value": "<?php\n\nnamespace Devlabs\\SportifyBundle\\Controller;\n\nuse Symfony\\Bundle\\FrameworkBundle\\Controller\\Controller;\nuse Sensio\\Bundle\\FrameworkExtraBundle\\Configuration\\Route;\nuse Devl...
php
chosen
[ { "from": "system", "value": "Update (function-list) to return a proper Desmond collection.\n" }, { "from": "human", "value": "<?php\nnamespace Desmond\\functions\\core;\nuse Desmond\\functions\\DesmondFunction;\nuse Desmond\\functions\\FileOperations;\nuse Desmond\\data_types\\ListType;\n\nclas...
php
chosen
[ { "from": "system", "value": "Update to universal Google Analytics" }, { "from": "human", "value": "\t\t\t<!-- footer -->\n\t\t\t<footer class=\"footer\" role=\"contentinfo\">\n\t\t\t\t\n\t\t\t\t<!-- copyright -->\n\t\t\t\t<p class=\"copyright\">\n\t\t\t\t\t&copy; <?php echo date(\"Y\"); ?> Copy...
php
chosen
[ { "from": "system", "value": "Create a new middlware instance instead of filter.\n\nShouldn't this be middleware?" }, { "from": "human", "value": "<?php\n\nnamespace App\\Http\\Middleware;\n\nuse Closure;\nuse Illuminate\\Contracts\\Auth\\Guard;\n\nclass Authenticate\n{\n /**\n * The Guar...
php
chosen
[ { "from": "system", "value": "chore: Add typehints to private function\n" }, { "from": "human", "value": "<?php\n\nnamespace PhpPact\\Standalone\\Installer\\Service;\n\nuse PhpPact\\Standalone\\Installer\\Model\\Scripts;\n\nclass InstallerPosixPreinstalled implements InstallerInterface\n{\n /...
php
chosen
[ { "from": "system", "value": "Test parameters in an array\n" }, { "from": "human", "value": "<?php\n\ndeclare(strict_types=1);\n\nnamespace Tests;\n\nuse Giuffre\\Sprint\\Sprint;\nuse PHPUnit\\Framework\\TestCase;\n\nclass SprintTest extends TestCase\n{\n public function testSprint()\n {\n...
php
chosen
[ { "from": "system", "value": "Fix bug in tests for PHPUnit 3.5.15\n" }, { "from": "human", "value": "<?php\ndate_default_timezone_set('UTC');\n\nif (substr(phpversion(), 0, 3) != '5.2') {\n error_reporting(E_ALL ^ E_DEPRECATED ^ E_NOTICE);\n}\n\ninclude __DIR__ . '/../paths.php';\n" }, { ...
php
chosen
[ { "from": "system", "value": "Use assertLessThan over simple assertTrue" }, { "from": "human", "value": "<?php\n\nnamespace Amp\\Dns\\Test;\n\nuse Amp\\Dns;\nuse Amp\\Loop;\nuse Amp\\PHPUnit\\TestCase;\nuse Amp\\Promise;\nuse LibDNS\\Messages\\Message;\nuse LibDNS\\Messages\\MessageTypes;\nuse L...
php
chosen
[ { "from": "system", "value": "Update registration of Twig view\n\nIt now maches the way the Twig-View readme suggests.\n" }, { "from": "human", "value": "<?php\n// DIC configuration\n\n$container = $app->getContainer();\n\n// ----------------------------------------------------------------------...
php
chosen
[ { "from": "system", "value": "Rename error page to explosion\n" }, { "from": "human", "value": "<?php\n\nrequire __DIR__.'/../vendor/autoload.php';\n\nuse Symfony\\Component\\HttpFoundation\\Request;\nuse Symfony\\Component\\HttpFoundation\\Response;\n\n$app = new Yolo\\Application();\n\n$app->g...
php
chosen
[ { "from": "system", "value": "Set Exception message for easier debugging\n" }, { "from": "human", "value": "<?php\n\nclass PodioError extends Exception {\n public $body;\n public $status;\n public $url;\n public function __construct($body, $status, $url) {\n $this->body = json_decode($bod...
php
chosen
[ { "from": "system", "value": "[drush] Improve drush command, make stand alone command\n" }, { "from": "human", "value": "<?php\n\n/**\n * @file\n * Contains \\Drupal\\Console\\Command\\DrushCommand.\n */\n\nnamespace Drupal\\Console\\Command;\n\nuse Symfony\\Component\\Console\\Input\\InputArgum...
php
chosen
[ { "from": "system", "value": "Allow custom validation error messages to be set on models\n" }, { "from": "human", "value": "<?php\n\n/**\n * Base model for Quill\n */\nclass BaseModel extends Eloquent {\n\n\tprotected $guarded = ['id'];\n\n\tpublic $errors;\n\n\tpublic function validate()\n\t{\n...
php
chosen
[ { "from": "system", "value": "Fix voor color selectie in filterlist\n" }, { "from": "human", "value": "<?php\nclass CustomTplHelper extends SpotTemplateHelper {\n\n\tfunction cat2color($spot) {\n\t\tswitch( (int) $spot['category']) {\n\t\t\tcase 0: return 'blue'; break;\n\t\t\tcase 1: return 'or...
php
chosen
[ { "from": "system", "value": "Fix short syntax for arrays\n" }, { "from": "human", "value": "<?php\n\n/**\n * CwsDumpHelper.\n *\n * A simple helper for CwsDump\n *\n * @author Cr@zy\n * @copyright 2013-2016, Cr@zy\n * @license GNU LESSER GENERAL PUBLIC LICENSE\n *\n * @link https://github.com/c...
php
chosen
[ { "from": "system", "value": "Fix: Split test cases and add test for DirectoryExists\n" }, { "from": "human", "value": "<?php\n/*\n * This file is part of sebastian/phpunit-framework-constraint.\n *\n * (c) Sebastian Bergmann <sebastian@phpunit.de>\n *\n * For the full copyright and license info...
php
chosen
[ { "from": "system", "value": "Add sorting for gridfield in modeladmin\n" }, { "from": "human", "value": "<?php\n\nclass StaffAdmin extends ModelAdmin\n{\n\n private static $managed_models = array(\n 'Staff',\n 'StaffCategory'\n );\n private static $url_segment = 'staff';\n privat...
php
chosen
[ { "from": "system", "value": "Set the allowed types in the constructor for backend init\n" }, { "from": "human", "value": "<?php\n\nnamespace Backend;\n\n/*\n * This file is part of Fork CMS.\n *\n * For the full copyright and license information, please view the license\n * file that was distri...
php
chosen
[ { "from": "system", "value": "Set timezone to UTC in tests\n" }, { "from": "human", "value": "<?php\n\nerror_reporting(E_ALL);\n\n$loader = require __DIR__.'/../vendor/autoload.php';\n$loader->addPsr4('Estaty\\\\Test\\\\', __DIR__);\n" }, { "from": "gpt", "value": "<?php\n\nerror_rep...
php
chosen
[ { "from": "system", "value": "Make test DSNs more customizable\n\nmysql is only tested if the mysqli extension exists.\n" }, { "from": "human", "value": "<?php\n#setup metrodb\ninclude_once('dataitem.php');\ninclude_once('connector.php');\n\nMetrodb_Connector::setDsn('default', 'mysqli://root:my...
php
chosen
[ { "from": "system", "value": "Remove autoloading the annotatino file" }, { "from": "human", "value": "<?php\n\n$file = __DIR__.'/../vendor/autoload.php';\nif (file_exists($file)) {\n $autoload = require $file;\n} else {\n throw new RuntimeException('Install dependencies to run test suite.'...
php
chosen
[ { "from": "system", "value": "Fix incorrect access token generation example\n" }, { "from": "human", "value": "<?php\n$user = \"<user>\"; // The user id\n$publicKey = \"<public key>\"; // The public key of the user\n$privateKey = \"<secret value>\"; // The private key of the use...
php
chosen
[ { "from": "system", "value": "Remove Input in favour of Request\n" }, { "from": "human", "value": "<?php namespace Forma;\n\nclass Helpers\n{\n\n public static function url($string)\n {\n if (static::isLaravel())\n {\n return \\URL::to($string);\n }\n\n ...
php
chosen
[ { "from": "system", "value": "Fix encoding issue PHP 5.4" }, { "from": "human", "value": "<?php\n\nnamespace Koara\\Io;\n\nclass FileReader implements Reader\n{\n\t\n\tprivate $fileName;\n\tprivate $index;\n\t\n\tpublic function __construct($fileName) \n\t{\n\t\t$this->fileName = $fileName;\n\t}...
php
chosen
[ { "from": "system", "value": "Add support for array properties rendering\n" }, { "from": "human", "value": "<?php\nnamespace Nayjest\\Grids;\n\nuse Exception;\nuse RuntimeException;\n\nclass ObjectDataRow extends DataRow\n{\n /**\n * @param string $fieldName\n * @return mixed\n * ...
php
chosen
[ { "from": "system", "value": "Upgrade ParameterEscaper. Fix some issues by translate.\n" }, { "from": "human", "value": "<?php\nnamespace Exercise\\GoogleTranslateBundle;\n\nclass ParametersEscaper\n{\n /** @var \\ArrayObject */\n protected $parametersArray;\n\n /** @var \\ArrayIterato...
php
chosen
[ { "from": "system", "value": "Remove URL from Gist embeds\n\nReverts the commit from 30f1aa3 and removes the Github Gist URL from\nappearing above the embedded gist.\n\nThe URLs are redundant as one could click the filename of the gist and\nbe taken to its page if they want.\n" }, { "from": "human",...
php
chosen
[ { "from": "system", "value": "Fix erors when no plugins\n" }, { "from": "human", "value": "<?php\n\nnamespace Rudolf\\Modules\\Plugins\\Roll\\Admin;\n\nuse Rudolf\\Component\\Plugins\\Manager as PluginsManager;\nuse Rudolf\\Framework\\Model\\BaseModel;\n\nclass Model extends BaseModel\n{\n /*...
php
chosen
[ { "from": "system", "value": "Fix endpoint url generation for graphiql\n" }, { "from": "human", "value": "<?php\ndeclare(strict_types=1);\n\nnamespace LotGD\\Crate\\GraphQL\\AppBundle\\Controller;\n\nuse Symfony\\Bundle\\FrameworkBundle\\Controller\\Controller;\nuse Sensio\\Bundle\\FrameworkExtr...
php
chosen
[ { "from": "system", "value": "Fix a typo in Artisan command description.\n" }, { "from": "human", "value": "<?php namespace Illuminate\\Foundation\\Console;\n\nuse Illuminate\\Console\\Command;\n\nclass UpCommand extends Command {\n\n\t/**\n\t * The console command name.\n\t *\n\t * @var string\...
php
chosen
[ { "from": "system", "value": "Add predictionIO api url to Config\n" }, { "from": "human", "value": "<?php\n\n\tConfigure::write('predictionIO', array(\n\t\t'appkey' => 'your-key',\n\t\t'userModel' => 'User',\n\t\t'engine' => ''\n\t));\n\n\t$files = array(\n\t\tApp::pluginPath('PredictionIO') . '...
php
chosen
[ { "from": "system", "value": "Edit error message for better debugging\n" }, { "from": "human", "value": "<?php\n\nrequire \"twilio-php-master/Services/Twilio.php\";\nrequire_once \"config.php\";\n\n\n\n\n$mysqli = new mysqli($HOST, $USER, $PASSWORD, $DATABASE);\n$client = new Services_Twilio($AC...
php
chosen
[ { "from": "system", "value": "Make Node\\Expr\\BinOp an abstract class\n\nOnly the children should be used ...\n" }, { "from": "human", "value": "<?php\n\nnamespace PhpParser\\Node\\Expr;\n\nuse PhpParser\\Node\\Expr;\n\n/**\n * @property Expr $left The left hand side expression\n * @property E...
php
chosen
[ { "from": "system", "value": "Update `nut init` for archive distributions have the site bundle files installed as .dist\n" }, { "from": "human", "value": "<?php\n\nnamespace Bolt\\Nut;\n\nuse Bolt\\Translation\\Translator as Trans;\nuse Bolt\\Version;\nuse Symfony\\Component\\Console\\Input\\Inp...
php
chosen
[ { "from": "system", "value": "Initialize doctrine models when storage is doctrine\n" }, { "from": "human", "value": "<?php\nnamespace Tbbc\\MoneyBundle\\DependencyInjection\\Compiler;\n\nuse Symfony\\Component\\DependencyInjection\\Compiler\\CompilerPassInterface;\nuse Symfony\\Component\\Depend...
php
chosen
[ { "from": "system", "value": "Test add 2 Factor Token. (We should move this to a modal instead)\n" }, { "from": "human", "value": "@extends('templates.master')\n\n@section('content')\n <form action=\"/login\" method=\"POST\">\n <input type=\"text\" name=\"username\" placeholder=\"Usern...
php
chosen
[ { "from": "system", "value": "Change fixed value in to const\n" }, { "from": "human", "value": "<?php\n\nnamespace GusApi\\Util;\n\nuse GusApi\\Type\\Response\\SearchDataResponse;\nuse GusApi\\Type\\Response\\SearchResponseCompanyData;\nuse GusApi\\Type\\Response\\SearchResponseRaw;\n\nclass Dat...
php
chosen
[ { "from": "system", "value": "Fix regex to account for windows.\n\nThe fixtures files are all \\n, so when the tests were run from windows none matched with PHP_EOL.\r\nThe new regex will match line endings of either OS." }, { "from": "human", "value": "<?php\n\ndeclare(strict_types=1);\n\nnames...
php
chosen
[ { "from": "system", "value": "Add insert method to the data manager\n" }, { "from": "human", "value": "<?php\n\nnamespace PhpAbac\\Manager;\n\nclass DataManager {\n /** @var \\PDO **/\n protected $connection;\n \n /**\n * @param \\PDO $connection\n */\n public function __c...
php
chosen
[ { "from": "system", "value": "Add `filename` option to configuration tree\n" }, { "from": "human", "value": "<?php\n\nnamespace Farmatholin\\SegmentIoBundle\\DependencyInjection;\n\nuse Symfony\\Component\\Config\\Definition\\Builder\\TreeBuilder;\nuse Symfony\\Component\\Config\\Definition\\Con...
php
chosen
[ { "from": "system", "value": "Change weird `array_map` by `foreach`\n" }, { "from": "human", "value": "<?php\n/*\n * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS\n * \"AS IS\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT\n * LIMITED TO, THE IMPLIED WARRANTIES ...
php
chosen
[ { "from": "system", "value": "Fix an error in the formula used to calculate an arithmetic series.\n" }, { "from": "human", "value": "<?php\n\nnamespace tomzx\\ProjectEuler;\n\nuse LogicException;\n\nclass Series\n{\n\t/**\n\t * @param int $n number of terms\n\t * @param float $a1 first term v...
php
chosen
[ { "from": "system", "value": "openid: Fix notice about unititialized variable.\n\ngit-svn-id: a243b28a2a52d65555a829a95c8c333076d39ae1@3027 44740490-163a-0410-bde0-09ae8108e29a\n" }, { "from": "human", "value": "<?php\n\n/* Find the authentication state. */\nif (!array_key_exists('AuthState', $_...
php
chosen
[ { "from": "system", "value": "Remove \"v\" shortcut (allready use for verbosity)" }, { "from": "human", "value": "<?php\n\n/*\n * This file is part of Octower.\n *\n * (c) William Pottier <developer@william-pottier.fr>\n *\n * For the full copyright and license information, please view the LICEN...
php
chosen
[ { "from": "system", "value": "Add FA icons to buttons\n" }, { "from": "human", "value": "@extends('crudapi::layouts.master')\n\n@section('content')\n <h1>{{ $model }}<button class=\"btn btn-sm btn-success pull-right\">Insert {{ $model }}</button></h1>\n\n <table class=\"table\">\n <tr>\...
php
chosen
[ { "from": "system", "value": "Fix project single view page\n" }, { "from": "human", "value": "<?php\n\nadd_action( 'init', 'create_project_posttype' );\n\nfunction create_project_posttype() {\n register_post_type( 'project',\n array(\n 'labels' => array(\n 'name' => __( 'Projects...
php
chosen
[ { "from": "system", "value": "FEATURE: Add PHPs json_encode options to stringify eel helper\n" }, { "from": "human", "value": "<?php\nnamespace Neos\\Eel\\Helper;\n\n/*\n * This file is part of the Neos.Eel package.\n *\n * (c) Contributors of the Neos Project - www.neos.io\n *\n * This package ...
php
chosen
[ { "from": "system", "value": "Remove old transport forcing code from the basic auth test\n" }, { "from": "human", "value": "<?php\n\nRequests::$transport = 'Requests_Transport_fsockopen';\n\nclass RequestsTest_Auth_Basic extends PHPUnit_Framework_TestCase {\n\tpublic static function transportPro...
php
chosen
[ { "from": "system", "value": "Add include for header and php\n" }, { "from": "human", "value": "<!DOCTYPE html>\n<html>\n <head>\n <meta charset=\"utf-8\">\n <title>Nos Bonbons</title>\n </head>\n <body>\n\n<?php\n\n ?>\n\n\n </body>\n</html>\n" }, { "from": "gpt", "value":...
php
chosen
[ { "from": "system", "value": "Load command schedules from the DB\n" }, { "from": "human", "value": "<?php\n\nnamespace App\\Console;\n\nuse Illuminate\\Console\\Scheduling\\Schedule;\nuse Illuminate\\Foundation\\Console\\Kernel as ConsoleKernel;\n\n/**\n * Class Kernel\n * @package App\\Console\...
php
chosen
[ { "from": "system", "value": "Set numeric textbox to use \"tel\" type so it gives a numeric textpad on mobile without showing up/down arrows in chrome\n" }, { "from": "human", "value": "<?php\n/**\n * Copyright (c) 2016 RhubarbPHP.\n *\n * Licensed under the Apache License, Version 2.0 (the \"Li...
php
chosen
[ { "from": "system", "value": "Make it easier to load config set by app/other plugin\n" }, { "from": "human", "value": "<?php\n$userMap = true;\n\nConfigure::write('Session', Hash::merge(\n\tConfigure::read('Session'),\n\tarray(\n\t\t'defaults' => 'php',\n\t\t'handler' => array(\n\t\t\t'engine' =...
php
chosen
[ { "from": "system", "value": "Fix setting of message via field's constructor\n" }, { "from": "human", "value": "<?php declare(strict_types = 1);\n\nnamespace Contributte\\ReCaptcha\\Forms;\n\nuse Contributte\\ReCaptcha\\ReCaptchaProvider;\nuse Nette\\Forms\\Container;\n\nfinal class InvisibleReC...
php
chosen
[ { "from": "system", "value": "Use instanceof instead of class_basename\n\n" }, { "from": "human", "value": "<?php\n\ndeclare(strict_types=1);\n\nnamespace Arcanedev\\Localization\\Middleware;\n\nuse Closure;\nuse Illuminate\\Http\\Request;\n\n/**\n * Class LocaleCookieRedirect\n *\n * @packa...
php
chosen
[ { "from": "system", "value": "Add getter for server config list\n" }, { "from": "human", "value": "<?php declare(strict_types=1);\n\nnamespace hollodotme\\Readis;\n\nuse hollodotme\\Readis\\Application\\Configs\\AppConfig;\nuse hollodotme\\Readis\\Infrastructure\\Redis\\ServerConnection;\nuse ho...
php
chosen