conversations
listlengths
2
3
source
stringclasses
1 value
stack
stringclasses
1 value
[ { "from": "system", "value": "Fix issue with ‘respect user's privacy’ code!\n\nIt’s Js and not PHP, stupid!\n" }, { "from": "human", "value": "<?php ///////////////////////////////////////////////////////\n// ----------------------------------------------------------\n// SNIPPET\n// ------------...
php
chosen
[ { "from": "system", "value": "Add role to transformed user data\n\nit wos sam what done this if it breaks" }, { "from": "human", "value": "<?php\nnamespace App\\Http\\Transformers\\Api\\v1;\n\nuse League\\Fractal\\TransformerAbstract as FractalTransformer;\nuse App\\Models\\User;\n\nclass UserTr...
php
chosen
[ { "from": "system", "value": "Remove direct dependency to security userinterface.\n" }, { "from": "human", "value": "<?php\n\n/**\n * This file is part of the pantarei/user package.\n *\n * (c) Wong Hoi Sing Edison <hswong3i@pantarei-design.com>\n *\n * For the full copyright and license informa...
php
chosen
[ { "from": "system", "value": "Add hyperlink to spendings in search view\n" }, { "from": "human", "value": "@extends('layout')\n\n@section('body')\n <h1>Search</h1>\n <form method=\"GET\" class=\"tight\">\n <div class=\"row spacing-top-large\">\n <div class=\"column\">\n ...
php
chosen
[ { "from": "system", "value": "Add new campaign type constant\n" }, { "from": "human", "value": "<?php\n\nnamespace directapi\\services\\campaigns\\enum;\n\nuse directapi\\components\\Enum;\n\nclass CampaignTypeEnum extends Enum\n{\n public const TEXT_CAMPAIGN = 'TEXT_CAMPAIGN';\n public co...
php
chosen
[ { "from": "system", "value": "[Address] Remove an address from book\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 distrib...
php
chosen
[ { "from": "system", "value": "Add link to upcoming events on the ended RSVP page\n" }, { "from": "human", "value": "<!DOCTYPE html>\n<html lang=\"en\">\n<head>\n <title>Event RSVP | MyRoboJackets</title>\n <meta name=\"viewport\" content=\"width=device-width, initial-scale=1\">\n <link ...
php
chosen
[ { "from": "system", "value": "Add div.clearfix to ensure links work in phone mode\n" }, { "from": "human", "value": "<?php\n/**\n * Default template for displaying post content\n *\n * @package ZnWP Bootstrap Theme\n */\n\nglobal $znwp_theme;\n?>\n\n <article id=\"post-<?php the_ID();...
php
chosen
[ { "from": "system", "value": "Use the generate token function from the wrapper while creating a new consumer\n" }, { "from": "human", "value": "<?php\n/**\n * @Author\tFreek Lijten\n */\nrequire_once(__DIR__ . '/../../lib/AutoLoader.php');\nnew AutoLoader();\n\n//generate random keys\n$handle = ...
php
chosen
[ { "from": "system", "value": "Change expected from `TINYINT` to `BOOLEAN`\n\nThe value of Boolean::$type was changed from `TINYINT` to `BOOLEAN` in a [commit](The https://github.com/zendframework/zf2/commit/e287ebfc9935e0fbc74998fe138aba67764250db) made by @SlayerBirden. It appears the tests were not change...
php
chosen
[ { "from": "system", "value": "Remove types in public and protected properies in not final classes (in components)\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, ple...
php
chosen
[ { "from": "system", "value": "Remove unnecessary output from curl when using pushover" }, { "from": "human", "value": "<?php\n\nnamespace Spatie\\Backup\\Notifications\\Senders;\n\nuse Illuminate\\Contracts\\Config\\Repository;\nuse Spatie\\Backup\\Notifications\\BaseSender;\n\nclass Pushover ex...
php
chosen
[ { "from": "system", "value": "Move tenant role seeding to cortex/tenants module\n" }, { "from": "human", "value": "<?php\n\ndeclare(strict_types=1);\n\nnamespace Cortex\\Fort\\Console\\Commands;\n\nuse Rinvex\\Fort\\Console\\Commands\\SeedCommand as BaseSeedCommand;\n\nclass SeedCommand extends ...
php
chosen
[ { "from": "system", "value": "Use 'self' as return type in accessor trait.\n" }, { "from": "human", "value": "<?php\n\nnamespace MusicBrainz\\Filter\\Accessor;\nuse MusicBrainz\\Filter\\Filter;\n\n/**\n * Provides accessors for the alias name\n */\ntrait AliasNameAccessorTrait\n{\n use Access...
php
chosen
[ { "from": "system", "value": "Add decimal length condition to phone migration\n" }, { "from": "human", "value": "<?php\n\n// skip conditions\n$skipped = true;\nif (!static::tableExists('people')) {\n printf(\"Skipping migration because table `people` does not exist yet\\n\");\n return stat...
php
chosen
[ { "from": "system", "value": "Remove unused function, return correct id\n\nIf id is requested master_id is needed\n" }, { "from": "human", "value": "<?php\nclass Kwc_Basic_Table_Trl_RowData extends Kwf_Model_Db_Row\n{\n public function getReplacedContent($field)\n {\n return Kwc_Bas...
php
chosen
[ { "from": "system", "value": "Set my email address from contact form\n" }, { "from": "human", "value": "<?php\n// Check for empty fields\nif(empty($_POST['name']) \t\t||\n empty($_POST['email']) \t\t||\n empty($_POST['phone']) \t\t||\n empty($_POST['message'])\t||\n !filter_var($_POST['...
php
chosen
[ { "from": "system", "value": "Add comment about why catching this error without handling it\n" }, { "from": "human", "value": "<?php\n\nnamespace Dock\\Doctor\\Action;\n\nuse Dock\\Docker\\Machine\\Machine;\nuse Dock\\Docker\\Machine\\MachineException;\nuse Dock\\Installer\\DockerInstaller;\nuse...
php
chosen
[ { "from": "system", "value": "Store complete data object inside mock.\n" }, { "from": "human", "value": "<?php\n/*\n * Copyright (c) Ouzo contributors, http://ouzoframework.org\n * This file is made available under the MIT License (view the LICENSE file for more information).\n */\nnamespace Ouz...
php
chosen
[ { "from": "system", "value": "Mark routing exception as deprecated.\n\nI don't want to change RedirectRoute or RoutingMiddleware at this time\nas I don't want to break compatibility over a small value change.\n" }, { "from": "human", "value": "<?php\ndeclare(strict_types=1);\n\n/**\n * CakePHP(t...
php
chosen
[ { "from": "system", "value": "Update parser unit tests according to new comment block indent system\n" }, { "from": "human", "value": "<?php\n\nnamespace Phug\\Test\\Parser\\TokenHandler;\n\nuse Phug\\Lexer;\nuse Phug\\Lexer\\Token\\TagToken;\nuse Phug\\Parser\\State;\nuse Phug\\Parser\\TokenHan...
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": "Mark lack of assertions as deliberate\n" }, { "from": "human", "value": "<?php\n\ndeclare(strict_types=1);\n\n/*\n * This file is part of the Sonata Project package.\n *\n * (c) Thomas Rabaix <thomas.rabaix@sonata-project.org>\n *\n * For the full copyright and lice...
php
chosen
[ { "from": "system", "value": "FIX wrong inclusion in test\n" }, { "from": "human", "value": "<?php\n\n use PHPUnit\\Framework\\TestCase;\n\n require_once '../Opbeat/client.php';\n\n class ClientTest extends TestCase {\n\n public function testGetErrorLevel() {\n $this->...
php
chosen
[ { "from": "system", "value": "Allow $page_type [body classes] to be specified, as well as $headExtra [contents transcluded into <head>]\n" }, { "from": "human", "value": "<?php\n\nif(!isset($blq))\n{\n\trequire_once(MODULES_ROOT . 'barlesque/client.php');\n\t$blq = new Barlesque();\n}\n$blq->fet...
php
chosen
[ { "from": "system", "value": "Remove phpcs ignores for base64 encode/decode.\n" }, { "from": "human", "value": "<?php\n/**\n * Base64_Encryption\n *\n * @package Google\\Site_Kit\\Tests\\Core\\Storage\n * @copyright 2019 Google LLC\n * @license https://www.apache.org/licenses/LICENSE-2.0 Apa...
php
chosen
[ { "from": "system", "value": "Disable autocomplete for client_id and client_secret inputs on Wave credentials form\n" }, { "from": "human", "value": "<?php\n\n/**\n * Form for Wave credentials.\n *\n * @license http://opensource.org/licenses/MIT The MIT License (MIT)\n */\n\nnamespace Wave\\Form...
php
chosen
[ { "from": "system", "value": "Fix Laravel Schema migrations for Cloud9\n" }, { "from": "human", "value": "<?php\n\nnamespace App\\Providers;\n\nuse Illuminate\\Support\\ServiceProvider;\n\nclass AppServiceProvider extends ServiceProvider\n{\n /**\n * Bootstrap any application services.\n ...
php
chosen
[ { "from": "system", "value": "Fix issue with config files\n" }, { "from": "human", "value": "<?php\n\n$domains = [\n\t'development' => ['localhost:3000'],\n\t'production' => ['production.com.br'],\n\t'staging' => ['staging.com.br']\n];\n\n$currentDomain = str_replace('www.', '', $_SERVER['HTTP_H...
php
chosen
[ { "from": "system", "value": "Add own class for each article attribute.\n" }, { "from": "human", "value": "@if($article->param('show_title'))\n<h3 class=\"article-title\">\n <a href=\"{{ url($article->alias) }}\">{{ $article->present()->title }}</a>\n</h3>\n@endif\n\n<div class=\"article-deta...
php
chosen
[ { "from": "system", "value": "Change test directory to get it work on travis ci\n" }, { "from": "human", "value": "<?php\n\nnamespace Tooly\\Tests\\Script\\Helper;\n\nuse org\\bovigo\\vfs\\vfsStream;\nuse phpmock\\phpunit\\PHPMock;\nuse Tooly\\Script\\Helper\\Filesystem;\n\n/**\n * @package Tool...
php
chosen
[ { "from": "human", "value": "Create functions to convert cases\n" }, { "from": "gpt", "value": "<?php\nclass CaseConverter {\n private $words;\n\n public function __construct(array $words) {\n if (!validate($words)) throw new TypeError('Passed array contains non-string elements');\n $thi...
php
chosen
[ { "from": "system", "value": "Add namespace back to Class Size\n" }, { "from": "human", "value": "<?php\n\n\nuse ReflectionClass;\n\nclass ClassSize\n{\n\n /**\n * @var ReflectionClass\n */\n private $sus;\n\n public function __construct(ReflectionClass $sus)\n {\n $th...
php
chosen
[ { "from": "system", "value": "Add missing proxy to trusted list\n" }, { "from": "human", "value": "<?php\n\nclass Request extends Kohana_Request {\n\t\n\tpublic static $trusted_proxies = array('127.0.0.1',\n\t\t\t\t\t\t\t\t\t\t\t'localhost',\n\t\t\t\t\t\t\t\t\t\t\t'localhost.localdomain',\n\t\t\...
php
chosen
[ { "from": "system", "value": "FIX Late static binding in config property for max age\n" }, { "from": "human", "value": "<?php\n\n/**\n * Abstract controller for actions that provide an API endpoint.\n */\nabstract class ApiController extends Controller\n{\n /**\n * Given a result payload,...
php
chosen
[ { "from": "system", "value": "Stop errors if no datasets are defined\n" }, { "from": "human", "value": "<?php\nrequire_once(\"/var/www/secure_settings/class.FlipsideSettings.php\");\nrequire_once('Autoload.php');\nclass DataSetFactory\n{\n static function get_data_set($set_name)\n {\n ...
php
chosen
[ { "from": "system", "value": "Fix CLI i18n (for real)\n" }, { "from": "human", "value": "#!/usr/bin/env php\n<?php\n\nuse Symfony\\Component\\Console\\Application;\n\nrequire_once __DIR__ . '/vendor/autoload.php';\n\ndate_default_timezone_set('Europe/Madrid');\n\n$loader = new \\Ontic\\Yaes\\Loa...
php
chosen
[ { "from": "system", "value": "Add attribute for 'contact' in person shortcode\n" }, { "from": "human", "value": "<?php\n\t# Member template for the 'medlem' shortcode function\n\t\n\t# The $meta includes member info\n\t# Uses a $content variable if available, otherwise the meta description of th...
php
chosen
[ { "from": "system", "value": "Add DatePart invalid date unit test\n" }, { "from": "human", "value": "<?php\nnamespace ZBateson\\MailMimeParser\\Header\\Part;\n\nuse PHPUnit_Framework_TestCase;\nuse DateTime;\n\n/**\n * Description of DateTest\n *\n * @group HeaderParts\n * @group DatePart\n * @c...
php
chosen
[ { "from": "system", "value": "Add usefull methods for working with childrens of menu" }, { "from": "human", "value": "<?php namespace Modules\\Menu\\Database\\Models;\n \nuse Illuminate\\Database\\Eloquent\\Model;\n\nclass Menu extends Model {\n\n\tpublic $table = 'menu';\n\n\tpublic $timestam...
php
chosen
[ { "from": "system", "value": "Add cDatePublic to indexed page list\n" }, { "from": "human", "value": "<?\n/**\n*\n* A wrapper class for results from the search engine, allowing for abstraction in case search engines are changed in the future.\n* @package Utilities\n* @subpackage Search\n*/\ndefi...
php
chosen
[ { "from": "system", "value": "Remove the french default page\n" }, { "from": "human", "value": "<?php namespace Modules\\Page\\Database\\Seeders;\n\nuse Illuminate\\Database\\Eloquent\\Model;\nuse Illuminate\\Database\\Seeder;\nuse Modules\\Page\\Repositories\\PageRepository;\n\nclass PageDataba...
php
chosen
[ { "from": "system", "value": "TASK: Add a missing method description" }, { "from": "human", "value": "<?php\nnamespace Neos\\Flow\\Http;\n\n/**\n * A Flow specific uploaded file.\n */\nclass FlowUploadedFile extends UploadedFile\n{\n /**\n * This is either the persistent identifier of a p...
php
chosen
[ { "from": "system", "value": "Remove logging code from Error Controller.\n" }, { "from": "human", "value": "<?php\n\nclass ErrorController extends Zend_Controller_Action\n{\n public function errorAction()\n {\n $errors = $this->_getParam('error_handler');\n \n switch (...
php
chosen
[ { "from": "system", "value": "Update service for mapping ids bydbxref\n" }, { "from": "human", "value": "<?php\n\nnamespace AppBundle\\API\\Mapping;\n\nuse AppBundle\\API\\Webservice;\nuse AppBundle\\Entity\\FennecUser;\nuse AppBundle\\Service\\DBVersion;\nuse Symfony\\Component\\HttpFoundation\...
php
chosen
[ { "from": "system", "value": "Fix to work with DataObjects" }, { "from": "human", "value": "<?php\n\nclass TestimonialsExtension extends SiteTreeExtension\n{\n\n private static $has_many = [\n 'Testimonials' => 'Testimonial'\n ];\n\n public function updateCMSFields(FieldList $fie...
php
chosen
[ { "from": "system", "value": "Fix classname to correct camelcase\n" }, { "from": "human", "value": "<?php\n/**\n * This file is part of the Napp\\AeroGearPush package.\n *\n * (c) NAPP <http://napp.dk>\n *\n * For the full copyright and license information, please view the LICENSE\n * file that ...
php
chosen
[ { "from": "system", "value": "Use \\Exception when in try-catch for pcre exceptions\n" }, { "from": "human", "value": "<?php\n\nnamespace Stamp\\Action;\n\nclass ParseVariableAction extends BaseAction implements ActionInterface\n{\n private $text = '';\n private $regex = '';\n\n public ...
php
chosen
[ { "from": "system", "value": "Make this a functional notifiable class\n" }, { "from": "human", "value": "<?php\n\nnamespace App;\n\nuse Illuminate\\Database\\Eloquent\\Model;\nuse Illuminate\\Database\\Eloquent\\SoftDeletes;\n\nclass RecruitingCampaignRecipient extends Model\n{\n use SoftDele...
php
chosen
[ { "from": "system", "value": "Set scheduler to run every hour on the 25th minute\n\nFixes ‘InvalidArgumentException : 5 is not a valid position’ when doing ‘artisan schedule:run’\n" }, { "from": "human", "value": "<?php\nreturn [\n\n /**\n * The storage config\n */\n \"storage\" =...
php
chosen
[ { "from": "system", "value": "Fix BC with setCode -> setStatusCode\n" }, { "from": "human", "value": "<?php\n/**\n * @author Patsura Dmitry @ovr <talk@dmtry.me>\n */\n\nnamespace RestApp\\Common\\Controller;\n\nuse Exception;\nuse ReflectionExtension;\n\n/**\n * Class IndexController\n * @Path(\...
php
chosen
[ { "from": "system", "value": "Add simple test to deprecated test class\n" }, { "from": "human", "value": "<?php\n\nclass Papi_Lib_Core_Deprecated_Test extends WP_UnitTestCase {\n\n\tpublic function setUp() {\n\t\tparent::setUp();\n\t\t$_GET = [];\n\n\t\tadd_action( 'deprecated_function_run', [$t...
php
chosen
[ { "from": "system", "value": "Make sure added methods are tested\n" }, { "from": "human", "value": "<?php\n\nuse Laravel\\Passport\\Passport;\nuse PHPUnit\\Framework\\TestCase;\n\nclass PassportTest extends TestCase\n{\n public function test_scopes_can_be_managed()\n {\n Passport::t...
php
chosen
[ { "from": "system", "value": "Revert \"Make logs dir if missing\"\n\nThis reverts commit ad9191f5c4cb65994aebcab2953f79c885c35248.\n" }, { "from": "human", "value": "<?php\n\nfunction debug_collectionInfoStart($debug, $log) {\n if ($debug == TRUE) {\n debug(\"[DEBUG] Collecting data\\n...
php
chosen
[ { "from": "system", "value": "Validate input file and support giving in a project directory" }, { "from": "human", "value": "<?php\n\nnamespace Clue\\PharComposer\\Command;\n\nuse Symfony\\Component\\Console\\Input\\InputOption;\nuse Symfony\\Component\\Console\\Input\\InputArgument;\nuse Symfon...
php
chosen
[ { "from": "system", "value": "Mark UIExamples as a prototype\n\nSummary: Ref T9103. This application is only useful for developing Phabricator, and in general is not kept \"production ready\". Mark it as a prototype.\n\nTest Plan: visit /applications/, see it marked as prototype.\n\nReviewers: epriestley\n\...
php
chosen
[ { "from": "system", "value": "Remove old button to submit the apppassword login\n\nSigned-off-by: John Molakvoæ (skjnldsv) <0835dbafb601d1e4088d26d0286d7121ba48453b@protonmail.com>\n" }, { "from": "human", "value": "<?php\n/**\n * @copyright Copyright (c) 2017 Lukas Reschke <lukas@statuscode.ch>...
php
chosen
[ { "from": "system", "value": "Update namespace and implement SimpleValueObject\n" }, { "from": "human", "value": "<?php\n\n/**\n * This file is part of the ValueObjects package.\n *\n * (c) Lorenzo Marzullo <marzullo.lorenzo@gmail.com>\n */\n\nnamespace ValueObjects\\Enum;\n\nuse MyCLabs\\Enum\\...
php
chosen
[ { "from": "system", "value": "Convert everything other than assets to app config\n\nWe're using Laravel's config resolving classes:\n\n```PHP\n$config = $app->make('config');\n$config->get('app.version'); // '5.7.0b2'\n```\n\n\nFormer-commit-id: 950db1326fe3a417acb509d4d2b572fda0cdd100" }, { "from":...
php
chosen
[ { "from": "system", "value": "Fix and add terminate to set Content-Type and Accept header\n" }, { "from": "human", "value": "<?php\n\nnamespace Stack;\n\nuse Symfony\\Component\\HttpFoundation\\Request;\nuse Symfony\\Component\\HttpKernel\\HttpKernelInterface;\n\nclass JsonRequest implements Htt...
php
chosen
[ { "from": "system", "value": "Rename modes param to playmodes and use get_arr directly\n" }, { "from": "human", "value": "<?php\n\n// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the GNU Affero General Public License v3.0.\n// See the LICENCE file in the repository root for full li...
php
chosen
[ { "from": "system", "value": "Add missing file level doc-block\n" }, { "from": "human", "value": "<?php\nnamespace Zend\\Config;\n\nuse Zend\\ServiceManager\\AbstractPluginManager;\n\nclass WriterPluginManager extends AbstractPluginManager\n{\n protected $invokableClasses = array(\n 'p...
php
chosen
[ { "from": "system", "value": "Fix FirstChildPage if child page doesn't exist\n" }, { "from": "human", "value": "<?php\nclass Kwc_Basic_LinkTag_FirstChildPage_Data extends Kwf_Component_Data\n{\n private $_pageCache = false;\n public function __get($var)\n {\n if ($var == 'url') {...
php
chosen
[ { "from": "system", "value": "Add file to test .\n" }, { "from": "human", "value": "<?php\n\n// change the following paths if necessary\n$yii=dirname(__FILE__).'/../../../yii/framework/yii.php';\n$config=dirname(__FILE__).'/protected/config/main.php';\n\n// remove the following lines when in pro...
php
chosen
[ { "from": "system", "value": "Store partner credentials as config.\n" }, { "from": "human", "value": "<?php\n\nabstract class ShippingEasy\n{\n public static $apiKey;\n public static $apiSecret;\n public static $apiBase = 'https://app.shippingeasy.com';\n public static $apiVersion = null;\n ...
php
chosen
[ { "from": "system", "value": "Fix email message sent when sheet contained errors.\n\n- Updated so the message about it including errors doesn't say to complete them by next week.\n- Always include message that stats aren't complete until regional declares them complete.\n" }, { "from": "human", ...
php
chosen
[ { "from": "system", "value": "Use imported class name instead of FQN\n" }, { "from": "human", "value": "<?php\n\nnamespace Tests\\Firebase\\Database\\Reference;\n\nuse Firebase\\Database\\Reference\\Validator;\nuse Firebase\\Exception\\InvalidArgumentException;\nuse GuzzleHttp\\Psr7\\Uri;\nuse P...
php
chosen
[ { "from": "system", "value": "Fix password column for future hashing\n" }, { "from": "human", "value": "<?php\n\nuse Illuminate\\Database\\Schema\\Blueprint;\nuse Illuminate\\Database\\Migrations\\Migration;\n\nclass CreateUsersTable extends Migration\n{\n /**\n * Run the migrations.\n ...
php
chosen
[ { "from": "system", "value": "Use redis method to distribute index.html file\n" }, { "from": "human", "value": "<?php\n\nnamespace Ilios\\WebBundle\\Controller;\n\nuse Symfony\\Bundle\\FrameworkBundle\\Controller\\Controller;\nuse Symfony\\Component\\HttpFoundation\\Response;\n\nclass IndexContr...
php
chosen
[ { "from": "system", "value": "Fix loader element permission detail\n\nFix loader element permission detail\n" }, { "from": "human", "value": "<?php defined('C5_EXECUTE') or die(\"Access Denied.\") ?>\n\n<?php $pk = PermissionKey::getByID($_REQUEST['pkID']) ?>\n<?php Loader::element('permission/d...
php
chosen
[ { "from": "system", "value": "Fix incorrect default share images.\n" }, { "from": "human", "value": "{{-- General social metadata --}}\n<link rel=\"canonical\" href=\"{{ URL::current() }}\"/>\n<meta name=\"description\"\n content=\"@yield('meta_description', 'Vote for your favorite ' . sett...
php
chosen
[ { "from": "system", "value": "Switch the Twig integration to use non-deprecated APIs" }, { "from": "human", "value": "<?php\n\nnamespace Knp\\Bundle\\MarkdownBundle\\Twig\\Extension;\n\nuse Knp\\Bundle\\MarkdownBundle\\Helper\\MarkdownHelper;\n\nclass MarkdownTwigExtension extends \\Twig_Extensi...
php
chosen
[ { "from": "system", "value": "Use class instead of helper.\n\nSigned-off-by: Mior Muhammad Zaki <e1a543840a942eb68427510a8a483282a7bfeddf@gmail.com>\n" }, { "from": "human", "value": "<?php\n\nnamespace Orchestra\\Database\\Console\\Migrations;\n\ntrait Packages\n{\n /**\n * The path to t...
php
chosen
[ { "from": "system", "value": "Allow setting the plates file extension\n" }, { "from": "human", "value": "<?php\n\nnamespace Rych\\Silex\\Provider;\n\nuse Silex\\Application;\nuse Silex\\ServiceProviderInterface;\nuse Rych\\Plates\\Extension\\RoutingExtension;\nuse Rych\\Plates\\Extension\\Securi...
php
chosen
[ { "from": "system", "value": "Use default parser on create.\n" }, { "from": "human", "value": "<?php\nnamespace Dersam\\RequestTracker\\Action\\Ticket;\n\nuse Dersam\\RequestTracker\\Action;\n\n/**\n *\n *\n * @author Sam Schmidt <samuel@dersam.net>\n * @since 2016-02-09\n */\nclass CreateTicket...
php
chosen
[ { "from": "system", "value": "Use email domain blacklist on reset password\n" }, { "from": "human", "value": "<?php\n\nnamespace App\\Http\\Controllers\\Auth;\n\nuse App\\Http\\Controllers\\Controller;\nuse Illuminate\\Foundation\\Auth\\SendsPasswordResetEmails;\n\nclass ForgotPasswordController...
php
chosen
[ { "from": "system", "value": "Set Python as default language.\n" }, { "from": "human", "value": "<?php\n\nnamespace App\\Units\\Home\\Http\\Controllers;\n\nuse App\\Domains\\Graphics\\FrameworkRadar;\nuse App\\Domains\\Graphics\\LanguagesIndex;\nuse App\\Domains\\Graphics\\LearningCurve;\nuse Ap...
php
chosen
[ { "from": "system", "value": "Remove string replace in favor of sprintf\n" }, { "from": "human", "value": "<?php\n\nclass Philwinkle_Fixerio_Model_Import extends Mage_Directory_Model_Currency_Import_Abstract\n{\n protected $_url = 'http://api.fixer.io/latest?base={{CURRENCY_FROM}}&symbols={{C...
php
chosen
[ { "from": "system", "value": "Fix service provider not registering SQS FIFO connector\n" }, { "from": "human", "value": "<?php\n\nnamespace Maqe\\LaravelSqsFifo;\n\nuse Illuminate\\Support\\ServiceProvider;\nuse Maqe\\LaravelSqsFifo\\Connectors\\SqsFifoConnector;\n\nclass LaravelSqsFifoServicePr...
php
chosen
[ { "from": "system", "value": "Call Session::init() to synchronize Session with $_SESSION\n" }, { "from": "human", "value": "<?php\n/**\n * @author Guillaume Gagnaire <contact@42php.com>\n * @link https://www.github.com/42php/42php\n * @license https://opensource.org/licenses/mit-...
php
chosen
[ { "from": "system", "value": "Resolve values before looking at them\n\nAt least for use_controller the default value defined in Symfony\\Bundle\\AsseticBundle\\DependencyInjection\\Configuration is \"%kernel.debug%\", which you will get literally as a string if you don't call resolveValue()." }, { "...
php
chosen
[ { "from": "system", "value": "Fix extending service provider name\n" }, { "from": "human", "value": "<?php\n\n/*\n * This file is part of Laravel Database.\n *\n * (c) Brian Faust <hello@brianfaust.de>\n *\n * For the full copyright and license information, please view the LICENSE\n * file that ...
php
chosen
[ { "from": "system", "value": "Fix Route Group interface. Added GetPattern method" }, { "from": "human", "value": "<?php\n\nnamespace Articstudio\\SlimInterfaces\\Contracts;\n\nuse Slim\\App as SlimApp;\n\ninterface RouteGroup {\n\n public function __invoke(SlimApp $app);\n}\n" }, { "f...
php
chosen
[ { "from": "system", "value": "Use new-password as autocomplete on share auth page\n\nFixes #6821\n\nThis makes sure that (supported) browsers will not prefill the password\nfield if a user has a password saved for that nextcloud.\n\nSigned-off-by: Roeland Jago Douma <982d370f7dc34a05b4abe8788f899578d515262d...
php
chosen
[ { "from": "system", "value": "Add magic method for http parse decorator.\n" }, { "from": "human", "value": "<?php\n/**\n * http parse decorator class\n * @author Lancer He <lancer.he@gmail.com>\n * @since 2014-10-28\n */\n\nnamespace Http\\Parse;\n\nuse Http\\Parse\\ParseAbstract;\n\nabstract c...
php
chosen
[ { "from": "system", "value": "Include jQuery in master layout\n" }, { "from": "human", "value": "<!doctype html>\n<html lang=\"en\">\n<head>\n\t<meta charset=\"UTF-8\">\n\t<title>Laravel PHP Framework</title>\n\n\t<link rel=\"stylesheet\" type=\"text/css\" href=\"/css/global.css\">\n\t<script ty...
php
chosen
[ { "from": "system", "value": "Move response::send to own line\n" }, { "from": "human", "value": "<?php\n\nnamespace Yolo;\n\nuse Symfony\\Component\\HttpFoundation\\Request;\nuse Symfony\\Component\\HttpKernel\\HttpKernelInterface;\nuse Symfony\\Component\\HttpKernel\\TerminableInterface;\n\ncla...
php
chosen
[ { "from": "system", "value": "Update charset of email config\n" }, { "from": "human", "value": "<?php\ndefined('BASEPATH') OR exit('No direct script access allowed');\n\nclass Emailing\n{\n private $ci;\n private $config;\n\n public function __construct()\n {\n $this->ci =& ge...
php
chosen
[ { "from": "system", "value": "FIX integration issues with Subsites\n\nvia guttmann/silverstripe-menumanager-subsites one can use the\nMenu Manager module while keeping menus segregated by Subsite and\nmanagable by each. However on dev/build the configured default\nmenus (see MenuSet::requireDefaultRecords) ...
php
chosen
[ { "from": "system", "value": "Add stream parameter on request\n" }, { "from": "human", "value": "<?php\nnamespace Icicle\\WebSocket\\Protocol\\Message;\n\nuse Icicle\\Http\\Message\\BasicRequest;\nuse Icicle\\Http\\Message\\Uri;\n\nclass WebSocketRequest extends BasicRequest\n{\n /**\n * ...
php
chosen
[ { "from": "system", "value": "Test mocking classes with methods returning references\n" }, { "from": "human", "value": "<?php\ndeclare(strict_types=1);\n\nnamespace Moka\\Tests;\n\nabstract class IncompleteAbstractTestClass implements TestInterface\n{\n public $public;\n\n protected $prote...
php
chosen
[ { "from": "system", "value": "BAP-16729: Remove DecoratorApiType and refactor dependent types\n- remove deprecated 'cascade_validation' option\n" }, { "from": "human", "value": "<?php\n\nnamespace Oro\\Bundle\\ApiBundle\\Form\\Type;\n\nuse Oro\\Bundle\\SoapBundle\\Form\\EventListener\\PatchSubsc...
php
chosen
[ { "from": "system", "value": "Set timezone for PHPUnit tess\n" }, { "from": "human", "value": "<?php\nset_include_path(dirname(__FILE__) . '/../' . PATH_SEPARATOR . get_include_path());\n\n// Enable Composer autoloader\nrequire dirname(__DIR__) . '/vendor/autoload.php';\n\n//Register non-Slim au...
php
chosen
[ { "from": "system", "value": "Add option to set a custom 503 content file with Config::inst()->update('MaintenanceMode', 'file', 'my503file');\n\nThis as fall back for a ErrorPage 503 file in assets.\n" }, { "from": "human", "value": "<?php\n\n/**\n * Class MaintenanceModeExtension\n *\n * @prop...
php
chosen
[ { "from": "system", "value": "Add nice looking path instead of the obscure '..'\n" }, { "from": "human", "value": "@extends('layout')\n\n@section('title')Folder - {{$path}}@stop\n\n@section('content')\n <h1>{{$path}}</h1>\n <?php\n if (strpos($path, \"/\")) {\n if(strpos(...
php
chosen
[ { "from": "system", "value": "Test if method buildViolation exist and fallback to addViolation for symfony < 2.5\n" }, { "from": "human", "value": "<?php\n/**\n * @author Marc Pantel <pantel.m@gmail.com>\n */\nnamespace Payum\\Core\\Bridge\\Symfony\\Validator\\Constraints;\n\nuse Symfony\\Compon...
php
chosen
[ { "from": "system", "value": "Add exception for missing/invalid dateFormat" }, { "from": "human", "value": "<?php namespace CodeIgniter\\Exceptions;\n\n/**\n * Model Exceptions.\n */\n\nclass ModelException extends FrameworkException\n{\n\tpublic static function forNoPrimaryKey(string $modelName...
php
chosen
[ { "from": "system", "value": "Test chmod of directory created by LocalStream\n" }, { "from": "human", "value": "<?php\n\nnamespace Gaufrette\\Functional\\FileStream;\n\nuse Gaufrette\\Filesystem;\nuse Gaufrette\\Adapter\\Local as LocalAdapter;\nuse Gaufrette\\Functional\\LocalDirectoryDeletor;\n...
php
chosen
[ { "from": "system", "value": "Add padding to ping nonce check - fixes failures\n" }, { "from": "human", "value": "<?php\n/**\n * Created by PhpStorm.\n * User: thomas\n * Date: 27/03/15\n * Time: 01:15\n */\n\nnamespace BitWasp\\Bitcoin\\Test\\Network\\Messages;\n\nuse BitWasp\\Bitcoin\\Bitcoin;...
php
chosen
[ { "from": "system", "value": "Fix generation of translated modules\n" }, { "from": "human", "value": "<?php\n\n/**\n * Created by PhpStorm.\n * User: Conrad\n * Date: 9/11/2015\n * Time: 5:28 PM\n */\nclass ContentModuleSiteTreeTranslatableExtension extends DataExtension\n{\n public function ...
php
chosen