conversations listlengths 2 3 | source stringclasses 1
value | stack stringclasses 1
value |
|---|---|---|
[
{
"from": "human",
"value": "Add execute function test suite.\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace Mimic\\Test;\n\nuse PHPUnit_Framework_TestCase;\nuse Mimic\\Functional as F;\n\n/**\n * Unit Test for either Mimic library function.\n *\n * @since 0.1.0\n */\nclass ExecuteFuncTest ... | php | chosen |
[
{
"from": "human",
"value": "Add file list date filter back in\n"
},
{
"from": "gpt",
"value": "<?php\n$this->params([\n 'filterFields' => $filterFields = isset($filterFields) ? $filterFields : [\n [\n 'class' => 'flex-2',\n 'partial' => 'date-min',\n ... | php | chosen |
[
{
"from": "human",
"value": "Add test for include/exclude expression in foreach cycle\n"
},
{
"from": "gpt",
"value": "<?php\n/**\n * Check performance drop from include/exclude expression in foreach cycle\n *\n * @file IncludeFunctionInForeach.php\n *\n * PHP version 5.4+\n *\n * @author ... | php | chosen |
[
{
"from": "human",
"value": "Add migration script for index additions\n"
},
{
"from": "gpt",
"value": "<?php\n\n// Check to ensure this file is included in Joomla!\ndefined('_JEXEC') or die('Restricted access');\n\nclass Migration20130410000000Core extends Hubzero_Migration\n{\n\tprotected stati... | php | chosen |
[
{
"from": "human",
"value": "Introduce command to create an institution configuration\n"
},
{
"from": "gpt",
"value": "<?php\n\n/**\n * Copyright 2016 SURFnet B.V.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with th... | php | chosen |
[
{
"from": "human",
"value": "BAP-16857: Fix running functional tests and investigate test failures\n- add tests\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace Oro\\Bundle\\TestFrameworkBundle\\Tests\\Unit\\DependencyInjection\\Compiler;\n\nuse Oro\\Bundle\\TestFrameworkBundle\\DependencyInj... | php | chosen |
[
{
"from": "human",
"value": "Create Abstract Database Connection Class.\n"
},
{
"from": "gpt",
"value": "<?php\n\nabstract class SQLayerDbo\n{\n\n /** @property *str* database directory **/\n protected $dbDir;\n \n /** @property *str* database name **/\n protected $dbName;\n \n... | php | chosen |
[
{
"from": "human",
"value": "Test for set parsedReceivedPayload event\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace Tests\\SlackAPI\\Events;\n\nuse PHPUnit\\Framework\\TestCase;\nuse SlackPHP\\SlackAPI\\Events\\ParsedReceivedEvent;\nuse SlackPHP\\SlackAPI\\Models\\Methods\\GroupsListRespon... | php | chosen |
[
{
"from": "human",
"value": "Add module for basic FP utilities (currying, id, etc)\n"
},
{
"from": "gpt",
"value": "<?php\n\nclass Basics {\n\n static function id($a) {\n return $a;\n }\n\n static function constant($a, $b) {\n return $a;\n }\n\n static function curry2(callable $f) {\n... | php | chosen |
[
{
"from": "human",
"value": "Remove db update version in db\n"
},
{
"from": "gpt",
"value": "<?php\n\nclass Migration_1488794963_RemoveDbUpdate implements \\CM_Migration_UpgradableInterface, \\CM_Service_ManagerAwareInterface {\n\n use CM_Service_ManagerAwareTrait;\n\n public function up(\... | php | chosen |
[
{
"from": "human",
"value": "Add semaphore from sync extension\n"
},
{
"from": "gpt",
"value": "<?php\nnamespace Icicle\\Concurrent\\Sync;\n\nuse Icicle\\Concurrent\\Exception\\SemaphoreException;\n\n/**\n * A wrapper for a semaphore based on the \"sync\" extension.\n */\nclass ExtSyncSemaphore ... | php | chosen |
[
{
"from": "human",
"value": "Add a listener service provider.\n"
},
{
"from": "gpt",
"value": "<?php namespace Illuminate\\Events;\n\nuse Illuminate\\Support\\ServiceProvider;\nuse Illuminate\\Contracts\\Events\\Dispatcher as DispatcherContract;\n\nclass ListenerServiceProvider extends ServicePr... | php | chosen |
[
{
"from": "human",
"value": "Add string key data builder\n"
},
{
"from": "gpt",
"value": "<?php declare(strict_types=1);\n\nnamespace hollodotme\\Readis\\Application\\ReadModel\\KeyDataBuilders;\n\nuse hollodotme\\Readis\\Application\\Interfaces\\ProvidesKeyInfo;\nuse hollodotme\\Readis\\Applica... | php | chosen |
[
{
"from": "human",
"value": "Implement cache manager to handle the PSR-6 drivers\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace PhpAbac\\Manager;\n\nuse Psr\\Cache\\CacheItemInterface;\n\nclass CacheManager {\n /** @var string **/\n protected $defaultDriver = 'memory';\n /** @var a... | php | chosen |
[
{
"from": "human",
"value": "Delete a file stored on the PixLab storage server"
},
{
"from": "gpt",
"value": "<?php\n/*\n * PixLab PHP Client which is just a single class PHP file without any dependency that you can get from Github\n * https://github.com/symisc/pixlab-php \n */\nrequire_once \"p... | php | chosen |
[
{
"from": "human",
"value": "Add tests for Locality class\n"
},
{
"from": "gpt",
"value": "<?php\n\nuse Galahad\\LaravelAddressing\\Country;\nuse Galahad\\LaravelAddressing\\Locality;\n\n/**\n * Class LocalityTest\n *\n * @author Junior Grossi <juniorgro@gmail.com>\n */\nclass LocalityTest exten... | php | chosen |
[
{
"from": "human",
"value": "Add tests for accessing the Stats controller\n"
},
{
"from": "gpt",
"value": "<?php\nnamespace App\\Test\\TestCase\\Controller;\n\nuse App\\Test\\TestCase\\Controller\\TatoebaControllerTestTrait;\nuse Cake\\Core\\Configure;\nuse Cake\\TestSuite\\IntegrationTestCase;\... | php | chosen |
[
{
"from": "human",
"value": "Create new 'number_helper', to house 'valid_database_id' check.\n"
},
{
"from": "gpt",
"value": "<?php if ( ! defined('BASEPATH')) exit('Invalid file request');\n\n/**\n * Pickr number helper methods.\n *\n * @package\t\t\tPickr\n * @author \t\t\tStephen Lewis <steph... | php | chosen |
[
{
"from": "human",
"value": "Include a class to interface with the USPS's API\n\nThis will allow us to normalize addresses.\n"
},
{
"from": "gpt",
"value": "<?php\n\n/**\n * USPS address standardization interface.\n *\n * A simple class to interface with the USPS's API to verify addresses.\n *\n... | php | chosen |
[
{
"from": "human",
"value": "Add tests for paginated list\n"
},
{
"from": "gpt",
"value": "<?php declare(strict_types=1);\n\nnamespace Becklyn\\RadBundle\\tests\\Pagination;\n\nuse Becklyn\\RadBundle\\Pagination\\PaginatedList;\nuse Becklyn\\RadBundle\\Pagination\\Pagination;\nuse PHPUnit\\Frame... | php | chosen |
[
{
"from": "human",
"value": "Add data type unit test.\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace Jivoo\\Models;\n\nclass DataTypeTest extends \\Jivoo\\Test {\n\n protected function _before() {}\n\n protected function _after() {}\n\n public function testDetectType() {\n $this->asse... | php | chosen |
[
{
"from": "human",
"value": "Add middleware for content negotiation\n\nIn case the content negotiation fails (because none of the formats we support is accepted), an `HTTP 406 Not acceptable` response is sent, listing the content types we support.\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamesp... | php | chosen |
[
{
"from": "human",
"value": "Change type of scr_period of Course\n"
},
{
"from": "gpt",
"value": "<?php\n\nuse Illuminate\\Support\\Facades\\Schema;\nuse Illuminate\\Database\\Schema\\Blueprint;\nuse Illuminate\\Database\\Migrations\\Migration;\n\nclass ChangeTypeOfScrPeriodInCourses extends Mig... | php | chosen |
[
{
"from": "human",
"value": "Add execution types controller tests\n"
},
{
"from": "gpt",
"value": "<?php\n/*\n * The MIT License (MIT)\n *\n * Copyright (c) 2016 Bruno P. Kinoshita, Peter Florijn\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy of\n * this sof... | php | chosen |
[
{
"from": "human",
"value": ":sparkles: Add new interface for config.\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace Risan\\OAuth1;\n\ninterface ConfigInterface\n{\n /**\n * Get the ClientCredentials instance.\n *\n * @return \\Risan\\OAuth1\\Credentials\\ClientCredentials\n ... | php | chosen |
[
{
"from": "human",
"value": "[*] Add migration for atlas changes\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace Application\\Migrations;\n\nuse Doctrine\\DBAL\\Migrations\\AbstractMigration,\n Doctrine\\DBAL\\Schema\\Schema;\n\n/**\n * Auto-generated Migration: Please modify to your need... | php | chosen |
[
{
"from": "human",
"value": "Add a few functional tests for the repository search controller\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace Tests\\Functional\\BackendBundle\\Controller;\n\nuse Tests\\Functional\\WebTestCase;\n\nclass TeamAddRepositoryControllerTest extends WebTestCase\n{\n ... | php | chosen |
[
{
"from": "human",
"value": "Create digital labels database table\n"
},
{
"from": "gpt",
"value": "<?php\n\nuse Illuminate\\Support\\Facades\\Schema;\nuse Illuminate\\Database\\Schema\\Blueprint;\nuse Illuminate\\Database\\Migrations\\Migration;\n\nclass CreateDigitalLabelsExhibitionsTables exte... | php | chosen |
[
{
"from": "human",
"value": "Add pluck function test suite.\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace Mimic\\Test;\n\nuse PHPUnit_Framework_TestCase;\nuse Mimic\\Functional as F;\n\n/**\n * Unit Test for pluck Mimic library function.\n *\n * @since 0.1.0\n */\nclass PluckFuncTest exten... | php | chosen |
[
{
"from": "human",
"value": "Add script to configure the test server.\n"
},
{
"from": "gpt",
"value": "<?php\n/**\n * Send an HTTP request.\n * @param string $method\n * @param string $url\n * @param array $bodyData\n * @return string|bool\n */\nfunction send_request($method, $url, array $bod... | php | chosen |
[
{
"from": "human",
"value": "Add src folder with Sample class code\n"
},
{
"from": "gpt",
"value": "<?php\n/**\n * Created by PhpStorm.\n * User: faramarz\n * Date: 1/16/17\n * Time: 12:57\n */\n\nnamespace FSalehpour\\PersianToolkit;\n\n\nclass SampleClass\n{\n\n}"
}
] | php | chosen |
[
{
"from": "human",
"value": "Add survey trigger endpoint handler for E2E.\n"
},
{
"from": "gpt",
"value": "<?php\n/**\n * Plugin Name: E2E Survey Trigger Interception\n * Description: REST Endpoint for bypassing survey trigger requests to the Site Kit service during E2E tests.\n *\n * @package ... | php | chosen |
[
{
"from": "human",
"value": "Drop `lake_uri` from all tables\n\nWe shouldn't be storing this in the database, since it can be generated\nusing `lake_guid`. In either case, these two resources are no longer\nbeing retrieved from the LAKE API, but rather, from CITI's API, so\nthese fields will become stale ve... | php | chosen |
[
{
"from": "human",
"value": "Add Exception class exists test (simple stuff)\n"
},
{
"from": "gpt",
"value": "<?php\n\nclass ExceptionTest extends PHPUnit_Framework_TestCase \n{\n /**\n * @test\n *\n * @covers Getopti\\Exception\n * \n * @author Braden Schaeffer\n */\n public func... | php | chosen |
[
{
"from": "human",
"value": "Add unique index to stop two pages with same path existing.\n\nEnforces at database level the condition that paths must be unique for a version of a site.\n\nMatthew and Sam can confirm the need for this...\n\nCould alternately have enforced this on site_id, parent_id, version a... | php | chosen |
[
{
"from": "human",
"value": "Add migration script to create new database table for b2share servers\n"
},
{
"from": "gpt",
"value": "<?php\n\ndeclare(strict_types=1);\n\nnamespace OCA\\B2shareBridge\\Migration;\n\nuse Closure;\nuse OCP\\DB\\ISchemaWrapper;\nuse OCP\\Migration\\SimpleMigrationStep... | php | chosen |
[
{
"from": "human",
"value": "Check timestamps go in order.\n"
},
{
"from": "gpt",
"value": "<?php\n\ninclude_once \"../www/includes/easyparliament/init.php\";\n\n$db = new ParlDB;\n$q = $db->query('select hansard.gid,time_to_sec(atime) as atime,hdate,hpos\n\tfrom hansard, video_timestamps\n\twhe... | php | chosen |
[
{
"from": "human",
"value": "Move back the customer delete example\n"
},
{
"from": "gpt",
"value": "<?php\n/*\nExample 23 - Delete a customer from mollie api.\n*/\n\ntry {\n /*\n * Initialize the Mollie API library with your API key or OAuth access token.\n */\n require \"initialize.php\";... | php | chosen |
[
{
"from": "human",
"value": "Add backwards compatibility test for schedule function\n"
},
{
"from": "gpt",
"value": "<?php\n\nuse PHPUnit\\Framework\\TestCase;\n\nclass BackwardsCompatibilityTest extends TestCase\n{\n public function testScheduleBackwardsCompatibility()\n {\n $teams... | php | chosen |
[
{
"from": "human",
"value": "Add base functional test class\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace Kmelia\\FreshBundle\\Tests;\n\nuse Symfony\\Bundle\\FrameworkBundle\\Test\\WebTestCase;\n\nclass BaseFunctionalTest extends WebTestCase\n{\n public function testIndex()\n {\n ... | php | chosen |
[
{
"from": "human",
"value": "Define an interface to build items controllers\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace WalletLogger;\n\nuse Slim\\Http\\Request;\nuse Slim\\Http\\Response;\n\ninterface ItemsInterface\n{\n public function getItem();\n\n public function createItem();... | php | chosen |
[
{
"from": "human",
"value": "Add doctrine:database:import command to load SQL files\n\nThere's already a command for that in Doctrine/DBAL."
},
{
"from": "gpt",
"value": "<?php\n\n/*\n * This file is part of the Doctrine Bundle\n *\n * For the full copyright and license information, please view ... | php | chosen |
[
{
"from": "human",
"value": "Add a phpunit test file for the Miscellaneous Provider\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace Faker\\Test\\Provider;\n\nuse Faker\\Provider\\Miscellaneous;\n\nclass MiscellaneousTest extends \\PHPUnit_Framework_TestCase\n{\n\n public function testBool... | php | chosen |
[
{
"from": "human",
"value": "Add migration for user's Conduit certificates.\n"
},
{
"from": "gpt",
"value": "<?php\n\nuse Illuminate\\Database\\Schema\\Blueprint;\nuse Illuminate\\Database\\Migrations\\Migration;\n\nclass AddConduitCertificateToUser extends Migration {\n\n\t/**\n\t * Run the mig... | php | chosen |
[
{
"from": "human",
"value": "Create an new Account(NEW ADMIN!)"
},
{
"from": "gpt",
"value": "<?php\nrequire_once(\"include/verify.php\");\nrequire_once(\"include/funktion.php\");\nrequire_once(\"include/layout.php\");\n$pdo = db_con();\n$zugang = readRegister($pdo);\ncreateUser($pdo, $zugang);\... | php | chosen |
[
{
"from": "human",
"value": "Add plugin file to ensure these files are picked up by scripts/update_po_templates.php.\n"
},
{
"from": "gpt",
"value": "<?php\n/**\n * StatusNet, the distributed open-source microblogging tool\n *\n * Plugin to enable LDAP Authentication\n *\n * PHP version 5\n *\n ... | php | chosen |
[
{
"from": "human",
"value": "Handle template, url rewriting and registering ajax action\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace QuanDigital\\LandingPage;\n\nuse QuanDigital\\WpLib\\Boilerplate;\nuse QuanDigital\\WpLib\\CreateCpt;\nuse Noodlehaus\\Config;\n\nclass Plugin extends Boile... | php | chosen |
[
{
"from": "human",
"value": "Move fuzzy search core into it's own class\n\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace eien\\Helpers;\n\nuse wataridori\\SFS\\SimpleFuzzySearch;\n\nclass BusSearch\n{\n public function searchServices($query, Cached $cached)\n {\n $serviceObject... | php | chosen |
[
{
"from": "human",
"value": "Sort an array and maintain index association\n"
},
{
"from": "gpt",
"value": "\n<?php\n$fruits = array(\"d\" => \"lemon\", \"a\" => \"orange\", \"b\" => \"banana\", \"c\" => \"apple\");\nasort($fruits);\nforeach ($fruits as $key => $val) {\n echo \"$key = $val\\n\... | php | chosen |
[
{
"from": "human",
"value": "Add small test for the const values\n"
},
{
"from": "gpt",
"value": "<?php namespace Katana\\Helpers;\n\nclass ConfigTest extends \\PHPUnit_Framework_TestCase {\n\n\t/**\n\t * Tests the value of the configuration values.\n\t */\n\tpublic function testConstsValues(){\... | php | chosen |
[
{
"from": "human",
"value": "tests: Add test to generate resources\n\nResource generation of the ui is triggered on the first access. This test\naccess the main page to trigger this generation. After this test all\nresources are available and no delay during accessing further pages should\ntake place.\n"
... | php | chosen |
[
{
"from": "human",
"value": "Create model for API keys\n"
},
{
"from": "gpt",
"value": "<?php namespace App\\Models;\n\nuse Illuminate\\Database\\Eloquent\\Model;\n\nclass ApiKey extends Model {\n \n /**\n * The attributes that should be casted to native types.\n * @var array\n ... | php | chosen |
[
{
"from": "human",
"value": "Add email verification status & token to user table\n"
},
{
"from": "gpt",
"value": "<?php\n\nuse Illuminate\\Support\\Facades\\Schema;\nuse Illuminate\\Database\\Schema\\Blueprint;\nuse Illuminate\\Database\\Migrations\\Migration;\n\nclass AddEmailVerificationFields... | php | chosen |
[
{
"from": "human",
"value": "Add missing test asset (git ignored by default)\n"
},
{
"from": "gpt",
"value": "<?php\nerror_reporting(error_reporting() & ~E_USER_DEPRECATED);\n\n// Delegate static file requests back to the PHP built-in webserver\nif (php_sapi_name() === 'cli-server'\n && is_fi... | php | chosen |
[
{
"from": "human",
"value": "Test access token creation using oAuth2\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace Slakbal\\Gotowebinar\\Test\\Unit;\n\nuse Slakbal\\Gotowebinar\\DirectLogin;\nuse Slakbal\\Gotowebinar\\Facade\\GotoWebinar;\nuse Slakbal\\Gotowebinar\\Test\\BaseTestCase;\n\nc... | php | chosen |
[
{
"from": "human",
"value": "Add tests on xliff files\n"
},
{
"from": "gpt",
"value": "<?php\n/*\n * This file is part of the Sonata project.\n *\n * (c) Thomas Rabaix <thomas.rabaix@sonata-project.org>\n *\n * For the full copyright and license information, please view the LICENSE\n * file that... | php | chosen |
[
{
"from": "human",
"value": "Create a command object for processing files copied into the auto_scan directory.\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace App\\Commands;\n\nclass AutoScanForNewFiles extends Command\n{\n /** @var bool */\n protected $autoScan;\n\n /**\n * Aut... | php | chosen |
[
{
"from": "human",
"value": "Add body class on RCP pages. props @cklosowski\n"
},
{
"from": "gpt",
"value": "<?php\n/**\n * Adds body classes to the registered pages in the Restrict Content Pro settings\n *\n * @param $classes\n *\n * @return array\n */\nfunction jp_add_body_classes( $classes ) ... | php | chosen |
[
{
"from": "human",
"value": "Add tests for user entity\n"
},
{
"from": "gpt",
"value": "<?php\nnamespace AppBundle\\Tests\\Entity;\nuse AppBundle\\Entity\\User;\nuse AppBundle\\Entity\\Item;\nuse Doctrine\\Common\\Collections\\ArrayCollection;\n/**\n * Class UserTest\n *\n * @author Prohorovych ... | php | chosen |
[
{
"from": "human",
"value": "Add test fo calendar update command\n"
},
{
"from": "gpt",
"value": "<?php\n$I = new AcceptanceTester($scenario);\n$I->wantTo('process tweets looking for beers');\n$I->runShellCommand('php artisan nerds:cal test');\n$I->seeInShellOutput('Not time to update');\n"
}
... | php | chosen |
[
{
"from": "human",
"value": "Add single file for mock classes.\n"
},
{
"from": "gpt",
"value": "<?php\n\nuse UWDOEM\\Framework\\FieldBearer\\FieldBearer;\n\nclass MockFieldBearer extends FieldBearer {\n\n public $saved = false;\n\n public function __construct() {}\n\n public function sa... | php | chosen |
[
{
"from": "human",
"value": "Add rudimentary goalie model for parser\n"
},
{
"from": "gpt",
"value": "<?php\n/*\n * Yes, thiswas copied straight across from SthsPlayer so all the bad decisions\n * were copied across and will have to be fixed here as well.\n */\nuse \\SparkLib\\DB;\n\nclass SthsG... | php | chosen |
[
{
"from": "human",
"value": "Add transformer for the gallery endpoint\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace Rogue\\Http\\Transformers;\n\nuse Rogue\\Models\\Post;\nuse Rogue\\Models\\Signup;\nuse League\\Fractal\\TransformerAbstract;\n\nclass PhoenixGalleryTransformer extends Trans... | php | chosen |
[
{
"from": "human",
"value": "Enhancement: Add test to prove autoloading fails\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace Snaggle\\Tests\\Client\\Credentials;\n\nuse PHPUnit_Framework_TestCase;\n\nclass TemporaryCredentialsTest extends PHPUnit_Framework_TestCase\n{\n public function t... | php | chosen |
[
{
"from": "human",
"value": "Test encrypting responses with a shared key.\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace MCordingley\\LaravelSapient\\Test\\Middleware;\n\nuse Illuminate\\Http\\Request;\nuse Illuminate\\Http\\Response;\nuse MCordingley\\LaravelSapient\\Middleware\\SharedEncr... | php | chosen |
[
{
"from": "human",
"value": "Add language deletion update script\n"
},
{
"from": "gpt",
"value": "<?php\n\nCM_Db_Db::truncate(\"cm_model_languagekey\");\n\n$langList = new CM_Paging_Language_All();\nforeach ($langList as $lang) {\n $lang->delete();\n}\n\n$serviceManager = CM_Service_Manager::... | php | chosen |
[
{
"from": "human",
"value": "Initialize testing script for pricer\n"
},
{
"from": "gpt",
"value": "<form method=\"post\" action=\"\">\n<input type=\"text\" name=\"value\">\n<input type=\"submit\">\n</form>\n\n<?php\ninclude_once(__DIR__ . '/GetLowestOfferListingsForASIN.php');\n\n$asin = array(\... | php | chosen |
[
{
"from": "human",
"value": "application: Add process forking class, and avoid accidentally using it for the web (it's cli only functionality)\n"
},
{
"from": "gpt",
"value": "<?php\n\n/**\n * Process forking implementation\n * @author M2Mobi, Heinz Wiesinger\n */\nclass Fork\n{\n\n /**\n ... | php | chosen |
[
{
"from": "human",
"value": "Delete orphan files maintenance script\n\nWhen deleting a profile it'll delete its notices and the coupling to\nfile entries, but not the file entries themselves (and thus not the\nfiles). So if one to delete a person uploading offending images, then\nthe images are left behind ... | php | chosen |
[
{
"from": "human",
"value": "Add first steps for module.\n"
},
{
"from": "gpt",
"value": "<?php\n\n/**\n * Plugin name: Self Publisher\n * Plugin URI: not-yet-here\n * Description: 'testets'\n * Version: 0.1\n * Author: The A-Team\n * License: TBA\n */\n\n// @TODO mechanism to store to db\n// @T... | php | chosen |
[
{
"from": "human",
"value": "Add additional indexes to some tables.\n\nThese indexes may or may not be redundant\n"
},
{
"from": "gpt",
"value": "<?php\n\nuse Illuminate\\Support\\Facades\\Schema;\nuse Illuminate\\Database\\Schema\\Blueprint;\nuse Illuminate\\Database\\Migrations\\Migration;\n\n... | php | chosen |
[
{
"from": "human",
"value": "Add new validation (not finished).\n"
},
{
"from": "gpt",
"value": "<?php\n\n\n/**\n * @author Andreas Kummer, w3concepts AG\n * @copyright Copyright © 2011, w3concepts AG\n */\n\nclass Aitsu_Form_Validation_Expression_Depending implements Aitsu_Form_Validation_... | php | chosen |
[
{
"from": "human",
"value": "Add unit test for sRequest class\n"
},
{
"from": "gpt",
"value": "<?php\nrequire './includes/global.inc';\n\nclass sRequestTest extends PHPUnit_Framework_TestCase {\n public function testCheckCSRFToken() {\n $csrf = fRequest::generateCSRFToken('/');\n $this->a... | php | chosen |
[
{
"from": "human",
"value": "Add template properties collection parser utility\n\nMethod is needed across multiple tasks, which is why this trait has\nbeen created.\n"
},
{
"from": "gpt",
"value": "<?php namespace Aedart\\Scaffold\\Collections\\Utility;\n\nuse Aedart\\Scaffold\\Containers\\IoC;\... | php | chosen |
[
{
"from": "human",
"value": "Update Config to be proerly namespaced\n"
},
{
"from": "gpt",
"value": "<?php\n /**\n * @category RCM\n * @author James Jervis <jjervis@relivinc.com>\n * @copyright 2012 Reliv International\n * @license License.txt New BSD License\n * @version GIT: reliv\n * ... | php | chosen |
[
{
"from": "human",
"value": "Add marker shape model class\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace Ivory\\GoogleMapBundle\\Model;\n\n/**\n * Marker shape which describes a google map marker shape\n * \n * @see http://code.google.com/apis/maps/documentation/javascript/reference.html#Ma... | php | chosen |
[
{
"from": "human",
"value": "Add server side code to delete case\n"
},
{
"from": "gpt",
"value": "<?php\n//script to edit and delete cases\nsession_start();\nrequire('../auth/session_check.php');\nrequire('../../../db.php');\n\n$action = $_POST['action'];\n\nif (isset($_POST['id']))\n\t{$id = $_... | php | chosen |
[
{
"from": "human",
"value": "AEIV-574: Add \"Calendar event Attendees\" into recipients autocompletion when sending emails\n"
},
{
"from": "gpt",
"value": "<?php\n\nnamespace Oro\\Bundle\\CalendarBundle\\Tests\\Unit\\Provider;\n\nuse Oro\\Bundle\\CalendarBundle\\Entity\\Repository\\AttendeeRepos... | php | chosen |
[
{
"from": "human",
"value": "Optimize HttpRaw, respond http headers in array\n"
},
{
"from": "gpt",
"value": "<?php\n\nrequire __DIR__ . '/../../vendor/autoload.php';\nrequire __DIR__ . '/../../vendor/dekuan/delib/src/CLib.php';\nrequire __DIR__ . '/../../src/CConst.php';\nrequire __DIR__ . '/..... | php | chosen |
[
{
"from": "human",
"value": "Add script to delete users in the delete queue.\n"
},
{
"from": "gpt",
"value": "<?php\n/**\n * Script to delete any Northstar users in the delete queue.\n *\n * to run:\n * drush --script-path=../scripts/ php-script delete-bad-users-in-northstar.php\n */\n\ninclude_... | php | chosen |
[
{
"from": "human",
"value": "Add migration for dash widgets\n"
},
{
"from": "gpt",
"value": "<?php\n\n/**\n * Migration: 8\n * Started: 07/11/2019\n *\n * @package Nails\n * @subpackage module-admin\n * @category Database Migration\n * @author Nails Dev Team\n * @link\n */\n\n... | php | chosen |
[
{
"from": "human",
"value": "Add the laravel queues functionality to do the jobs later.\n"
},
{
"from": "gpt",
"value": "<?php namespace App\\Commands;\n\nuse App\\Commands\\Command;\n\nuse Illuminate\\Queue\\SerializesModels;\nuse Illuminate\\Queue\\InteractsWithQueue;\nuse Illuminate\\Contract... | php | chosen |
[
{
"from": "human",
"value": "Add first tool: a simple normalisation script.\n"
},
{
"from": "gpt",
"value": "<?php\n/**\n * Normalise a HXL dataset.\n *\n * Usage:\n *\n * php hxlnorm.php < INFILE.csv > OUTFILE.csv\n *\n * Started by David Megginson, 2014-09-26\n */\n\nrequire_once(__DIR__ . '/.... | php | chosen |
[
{
"from": "human",
"value": "Introduce global view parameters service\n"
},
{
"from": "gpt",
"value": "<?php\n\n/**\n * Copyright 2016 SURFnet B.V.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * Y... | php | chosen |
[
{
"from": "human",
"value": "Add migration for social posts table\n"
},
{
"from": "gpt",
"value": "<?php\n\nuse Illuminate\\Database\\Schema\\Blueprint;\nuse Illuminate\\Database\\Migrations\\Migration;\n\nclass CreateSocialPostsTable extends Migration {\n\n\t/**\n\t * Run the migrations.\n\t *\... | php | chosen |
[
{
"from": "human",
"value": "Add test cases for `TwigRuntimeLoader`\n"
},
{
"from": "gpt",
"value": "<?php\n/**\n * Slim Framework (http://slimframework.com)\n *\n * @license https://github.com/slimphp/Twig-View/blob/master/LICENSE.md (MIT License)\n */\n\ndeclare(strict_types=1);\n\nnamespace... | php | chosen |
[
{
"from": "human",
"value": "Add basic TourDates element test\n"
},
{
"from": "gpt",
"value": "<?php\n\nrequire_once('tests/php/base.php');\nrequire_once('framework/php/classes/elements/TourDates.php');\n\nclass ElementTests extends UnitTestCase {\n\tfunction testTourDates(){\n\t\t$e = new TourD... | php | chosen |
[
{
"from": "system",
"value": "Add --quiet option to avoid log limitation\n"
},
{
"from": "human",
"value": "<?php\nuse PhpBrew\\Testing\\CommandTestCase;\n\nclass DownloadCommandTest extends CommandTestCase\n{\n\n public function versionDataProvider() {\n return array(\n arr... | php | chosen |
[
{
"from": "human",
"value": "Move Anqh specific routes from bootstrap\n"
},
{
"from": "gpt",
"value": "<?php defined('SYSPATH') or die('No direct access allowed.');\n/**\n * Init for Anqh\n *\n * @package Anqh\n * @author Antti Qvickström\n * @copyright (c) 2010 Antti Qvickström\n * @lic... | php | chosen |
[
{
"from": "human",
"value": "Add an example program to view \"bounding polygon\"\n"
},
{
"from": "gpt",
"value": "#!/usr/bin/env php\n<?php\ninclude(\"NudeDetector.php\");\n\n$method = 'HSV';\n\nif ($argc == 1)\n\texit;\n\n$input_file = $argv[1];\n\n$detector = new NudeDetector($input_file, $met... | php | chosen |
[
{
"from": "human",
"value": "Add logic boxes config file.\n"
},
{
"from": "gpt",
"value": "<?php\n\nreturn [\n\t\n\t\"test_mode\" => env('LB_TEST_MODE', true),\n\t\"auth_userid\" => env('LB_AUTH_USERID', ''),\n\t\"api_key\" => env('LB_API_KEY', ''),\n\n];"
}
] | php | chosen |
[
{
"from": "human",
"value": "Set template for contact us page\n- Display the information from the hours of operations admin configuration\n"
},
{
"from": "gpt",
"value": "<?php get_header(); ?>\n\t<div id=\"content\" class=\"container\">\n\t\t<div id=\"inner-content\" class=\"row\">\n\t\t\t<main... | php | chosen |
[
{
"from": "human",
"value": "Add Redirect to Library Catalog\n"
},
{
"from": "gpt",
"value": "<?php\n\nheader('Location: https://docs.google.com/spreadsheets/d/1t_sxZH7jvzOluM8tILO-m4LGJ8op-Uqwp5MM4vlVgQ0/pubhtml?widget=true&headers=false');\n\n?>\n"
}
] | php | chosen |
[
{
"from": "system",
"value": "Check apc.enable_cli for ApcTestCase unit tests\n"
},
{
"from": "human",
"value": "<?php\nnamespace yiiunit\\framework\\caching;\nuse yii\\caching\\ApcCache;\nuse yiiunit\\TestCase;\n\n/**\n * Class for testing APC cache backend\n */\nclass ApcCacheTest extends Cach... | php | chosen |
[
{
"from": "human",
"value": "Add test for money function\n"
},
{
"from": "gpt",
"value": "<?php\nrequire_once __DIR__ . '/../../../TestCase.php';\n\nrequire_once CM_Util::getNamespacePath('CM') . 'library/CM/SmartyPlugins/function.money.php';\n\nclass smarty_function_moneyTest extends TestCase {... | php | chosen |
[
{
"from": "human",
"value": "Add a first test for the Wall model\n"
},
{
"from": "gpt",
"value": "<?php\nApp::uses('Wall', 'Model');\n\nclass WallTest extends CakeTestCase {\n\n public $fixtures = array(\n 'app.wall',\n );\n\n public function setUp() {\n parent::setUp();\n... | php | chosen |
[
{
"from": "human",
"value": "Include a migration to disable the enterprise_key app if present\n"
},
{
"from": "gpt",
"value": "<?php\nnamespace OC\\Migrations;\n\nuse OCP\\Migration\\ISimpleMigration;\nuse OCP\\Migration\\IOutput;\n\n/**\n * Disable enterprise_key app during the upgrade to 10.5.... | php | chosen |
[
{
"from": "human",
"value": "Add support for contact persons endpoints\n\n| Q | A\n| ------------- | ---\n| Branch | master\n| Bug fix? | no\n| New feature? | yes\n| BC breaks? | no\n| Deprecations? | no\n| Tests pass? | yes\n| Fixed tickets | n/a\n| License | MIT\n| Doc ... | php | chosen |
[
{
"from": "human",
"value": "Add migration file for creating profile table\n"
},
{
"from": "gpt",
"value": "<?php\n\nuse yii\\db\\Migration;\n\n/**\n * Handles the creation for table `profile`.\n */\nclass m160622_095150_create_profile extends Migration\n{\n /**\n * @inheritdoc\n */\n... | php | chosen |
[
{
"from": "human",
"value": "Add test for twig rendering\n"
},
{
"from": "gpt",
"value": "<?php\n\n\nnamespace LastCall\\Patterns\\Twig\\Tests\\Renderer;\n\n\nuse LastCall\\Patterns\\Core\\Pattern\\PatternInterface;\nuse LastCall\\Patterns\\Core\\Variable\\VariableSet;\nuse LastCall\\Patterns\\T... | php | chosen |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.