conversations
listlengths
2
3
source
stringclasses
1 value
stack
stringclasses
1 value
[ { "from": "system", "value": "TEST added core-js to loading libraries for test suite\n" }, { "from": "human", "value": "module.exports = function(config) {\n config.set({\n basePath: '',\n frameworks: ['jasmine'],\n files: [\n { pattern: 'test/**/*.js', watched: false }\n ],\n ...
javascript
chosen
[ { "from": "system", "value": "Resolve .jsx extensions from test build\n" }, { "from": "human", "value": "// Karma configuration\n// Generated on Tue Jul 28 2015 16:29:51 GMT+0200 (CEST)\nvar webpack = require(\"webpack\");\n\nvar CONTINUOUS_INTEGRATION = process.env.CONTINUOUS_INTEGRATION === \"...
javascript
chosen
[ { "from": "system", "value": "Include all of the files in test coverage report\n" }, { "from": "human", "value": "const webpackConfig = require('./webpack.config.babel')({env: 'test'});\nconst fileGlob = 'src/**/*.test.js';\n\nmodule.exports = config => {\n config.set({\n basePath: '',\n ...
javascript
chosen
[ { "from": "system", "value": "Load all source files in Karma\n" }, { "from": "human", "value": "'use strict';\n\nmodule.exports = function(config) {\n config.set({\n 'basePath': '',\n 'frameworks': ['jasmine'],\n 'files': [\n 'bower_components/jquery/dist/jquery.js',\n 'bower...
javascript
chosen
[ { "from": "system", "value": "Handle leading whitespace in signature.\n" }, { "from": "human", "value": "'use strict';\n\nvar {pluck} = require('./underscore_ext');\nvar parser = require('./models/geneSignatureParser').parse;\n// Parse a simple list of genes and weights. More complex signatures ...
javascript
chosen
[ { "from": "system", "value": "Remove defunct missing attribute error generator\n" }, { "from": "human", "value": "// A catch-all error\nfunction genericError() {\n return {\n title: \"Server Error\",\n detail: \"There was an error while processing your request.\"\n };\n}\n\n// Generates ...
javascript
chosen
[ { "from": "system", "value": "Use correct db settings in populate job postings\n" }, { "from": "human", "value": "var config = require('../../app/config')\n , models = require('../../app/models')\n , logger = require('../../app/logger');\n\n\nvar mongoose = require('mongoose'),\n fs = requi...
javascript
chosen
[ { "from": "system", "value": "ADD show env-value on build\n" }, { "from": "human", "value": "const webpack = require('webpack');\nconst webpackMerge = require('webpack-merge');\nconst commonConfig = require('./webpack.config.common.js');\nconst AppCachePlugin = require('appcache-webpack-plugin')...
javascript
chosen
[ { "from": "system", "value": "Add both build id / git commit sha via @hone\n" }, { "from": "human", "value": "'use strict';\n\nlet cli = require('heroku-cli-util');\nlet columnify = require('columnify');\n\nmodule.exports = {\n topic: 'builds',\n needsAuth: true,\n needsApp: true,\n de...
javascript
chosen
[ { "from": "system", "value": "Fix bug generated when the change of value -> message\n" }, { "from": "human", "value": "jQuery(function($) {\n kamo.Stream.fromEventHandlerFunction(\n $('#input'),\n 'keyup'\n ).debounce(1000).map(function(event) {\n return event.target.message;\n }).fi...
javascript
chosen
[ { "from": "system", "value": "Use a placeholder for body content.\n" }, { "from": "human", "value": "import { Component } from 'substance'\n\nexport default class BodyComponent extends Component {\n\n render($$) {\n const body = this.props.node\n let el = $$('div')\n .addClass('sc-bo...
javascript
chosen
[ { "from": "system", "value": "Remove callback route. Not needed." }, { "from": "human", "value": "/**\n * A ping federate example of how to use `hapi-auth-saml`\n */\nvar Hapi = require('hapi');\n\nvar port = 7771;\nvar server = Hapi.createServer(port);\n\nvar SamlAuth = require('../lib');\n\nva...
javascript
chosen
[ { "from": "system", "value": "Fix back to top icon not appearing on webkit browsers\n" }, { "from": "human", "value": "// @license magnet:?xt=urn:btih:0b31508aeb0634b347b8270c7bee4d411b5d4109&dn=agpl-3.0.txt AGPL-v3-or-Later\n\napp.views.BackToTop = Backbone.View.extend({\n events: {\n \"cli...
javascript
chosen
[ { "from": "system", "value": "Change hour value of sending reports to env var\n\n - With name REPORTS_HOUR\n\nSigned-off-by: Felipe Milani <6def120dcec8fcb28aed4723fac713cfff66d853@gmail.com>\n" }, { "from": "human", "value": "import { SyncedCron } from 'meteor/percolate:synced-cron';\nimport se...
javascript
chosen
[ { "from": "system", "value": "Load from server on initialisation\n" }, { "from": "human", "value": "\"use strict\";\n\nvar ko = require(\"knockout\");\nvar zepto = require(\"npm-zepto\");\n\nko.bindingHandlers.enterkey = require(\"./bindings/enterkey.js\");\n\nvar localForage = require(\"localfo...
javascript
chosen
[ { "from": "system", "value": "Fix default SVG optimisation configuration\n" }, { "from": "human", "value": "'use strict'; // eslint-disable-line\n\nconst { default: ImageminPlugin } = require('imagemin-webpack-plugin');\nconst imageminMozjpeg = require('imagemin-mozjpeg');\n\nconst config = requ...
javascript
chosen
[ { "from": "system", "value": "Add markers using web sockets\n" }, { "from": "human", "value": "$(function() {\n var osm = L.tileLayer('http://{s}.tile.osm.org/{z}/{x}/{y}.png', {\n attribution: '&copy; <a href=\"http://osm.org/copyright\">OpenStreetMap</a> contributors'\n });\n\n ...
javascript
chosen
[ { "from": "system", "value": "Fix warnings, and use only one var keyword per function.\n" }, { "from": "human", "value": "/*\n * Copyright 2012 Netflix, Inc.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the Lice...
javascript
chosen
[ { "from": "human", "value": "Implement the create document function\n" }, { "from": "gpt", "value": "'use strict';\n\nconst models = require('./../models/');\nconst docModel = models.Documents;\nconst dotenv = require('dotenv').config();\nconst docHelper = require('./helpers/docHelper...
javascript
chosen
[ { "from": "system", "value": "Decrease reset delay to 10 seconds.\n" }, { "from": "human", "value": "/*global CpuSolver GpuSolver Maze */\n\nvar RESET_DELAY = 30 * 1000;\n\nfunction nearest(dim, scale) {\n var floor = Math.floor(dim / scale);\n return (floor % 2 == 0) ? floor - 1 : floor;\...
javascript
chosen
[ { "from": "system", "value": "Access h2 element inside flashcard\n" }, { "from": "human", "value": "var questions = [\n Q1 = {\n question: \"What do HTML means?\",\n answer: \"HyperText Markup Language\"\n },\n Q2 = {\n question: \"What do CSS means?\",\n answer: \"Cascading Style...
javascript
chosen
[ { "from": "system", "value": "Make sure only version on index page gets AJAXed\n" }, { "from": "human", "value": "var URL = location.pathname;\n\n$(function() {\n\thighlight();\n\tfetchVersion();\n});\n\nfunction highlight() {\n\t$(\"#menu a[href='\" + URL + \"']\").addClass(\"active\");\n}\n\nf...
javascript
chosen
[ { "from": "system", "value": "[jb] Fix broken page after reloading the Impala query details in the Job Browser\n" }, { "from": "human", "value": "// Licensed to Cloudera, Inc. under one\n// or more contributor license agreements. See the NOTICE file\n// distributed with this work for additional...
javascript
chosen
[ { "from": "system", "value": "Update postWriter tests to work\n" }, { "from": "human", "value": "/*eslint-env node, qunit, mocha */\n\"use strict\";\n\ndescribe(\"myApp.view1 module\", function() {\n\n beforeEach(module(\"myApp.view1\"));\n\n describe(\"view1 controller\", function(){\n\n ...
javascript
chosen
[ { "from": "system", "value": "Improve the spec descriptions in ContextSpecification.\n" }, { "from": "human", "value": "describe('jasmine.grammar.ContextSpecification', function() {\n var ContextSpecification = jasmine.grammar.ContextSpecification;\n var env;\n \n beforeEach(func...
javascript
chosen
[ { "from": "system", "value": "Hide delete button on subsequent tabs\n" }, { "from": "human", "value": "function removeRedundantTabs() {\n var t = 0;\n if (django && django.jQuery) {\n django.jQuery('.changeform-tabs-item:contains(\"General\")').each(function(index, tab){\n ...
javascript
chosen
[ { "from": "system", "value": "Change the logout form the verb GET to the verb POST (and only)\n\nSigned-off-by: Henrique Vicente <d390f26e2f50ad5716a9c69c58de1f5df9730e3b@gmail.com>\n" }, { "from": "human", "value": "/*global angular */\n\n(function () {\n 'use strict';\n\n angular.module(...
javascript
chosen
[ { "from": "system", "value": "Fix incorrect Grid drawPath method.\n" }, { "from": "human", "value": "/*globals Polygon*/\n/*exported Grid*/\nvar Grid = (function() {\n 'use strict';\n\n function Grid( options ) {\n Polygon.call( this );\n\n options = options || {};\n\n this.width = o...
javascript
chosen
[ { "from": "system", "value": "Fix file name for Linux / case-sensitive file systems\n\nOn Linux, when running trying to run the editor, globalRootRegistry.js could not be found:\r\nError /home/dali/src/dreem2-dev/lib/dr/globals/globalRootRegistry.js In teemserver.js request handling. File not found, returni...
javascript
chosen
[ { "from": "system", "value": "Add sync logging and tweet logging\n" }, { "from": "human", "value": "var\n schedule = require('node-schedule'),\n tweet = require('./tweet'),\n syncTask = require('./tasks/sync');\n\n// Tasks to run on startup\nsyncTask.run();\n\n// Update entries every 30 minut...
javascript
chosen
[ { "from": "system", "value": "Remove unused command line options parsing code\n\nSigned-off-by: Sonmez Kartal <d2d15c3d37396a5f2a09f8b42cf5f27d43a3fbde@koding.com>\n" }, { "from": "human", "value": "require('coffee-script').register();\nmodule.exports = require('./lib/auth/main');\n\nvar argv ...
javascript
chosen
[ { "from": "system", "value": "fix(Service): Fix disappearing cursor in services\n\nWorkaround for disappearing cursors in webviews" }, { "from": "human", "value": "import React, { Component } from 'react';\nimport PropTypes from 'prop-types';\nimport { observer } from 'mobx-react';\nimport Elect...
javascript
chosen
[ { "from": "system", "value": "Create polling helpers for thumbs and multipoll\n" }, { "from": "human", "value": "var Teachers = require('../models/teachers');\nvar TeacherClasses = require('../models/Teacher_classes');\nvar Classes = require('../models/classes');\nvar ClassLessons = require('../...
javascript
chosen
[ { "from": "system", "value": "Remove specifying rootURL from ENV\n\nSpecifying a rootURL should be optional and not based on the ENV rootURL, which should only be used to namespace assets in the `base href` tag. The previous functionality resulted in a bug where you would get a double url parameter if you s...
javascript
chosen
[ { "from": "system", "value": "Fix web route for file upload\n" }, { "from": "human", "value": "module.exports = ({\n config\n}) => {\n\n const upload = require('multer')({\n dest: config.upload.path\n });\n\n return (route, app) => {\n\n app.post(route,\n upload.any(),\n func...
javascript
chosen
[ { "from": "system", "value": "Add comments to the initial migration." }, { "from": "human", "value": "\nexports.up = function(knex, Promise) {\n return knex.schema.createTable('course', function(table) {\n table.increments('id').primary();\n table.string('name');\n table.string('code')...
javascript
chosen
[ { "from": "system", "value": "Fix issue with Ember 2.5.0-beta.1.\n\nEmber 2.5.0-beta.1 includes a \"local lookup\" feature, that calls\n`componentFor` twice with different arguments:\n\n1 `name, owner, { source }` -- Added options with `source` so that\n resolver can do local lookup logic based on the inv...
javascript
chosen
[ { "from": "system", "value": "Add new utility find function for converting id to longname for unit fields\n" }, { "from": "human", "value": "\n\nvar ObjectEditor = {\n Data: {\n Units: require('../WEdata/data/Units.json')\n },\n Fields: {\n Units: require('../WEdata/fields...
javascript
chosen
[ { "from": "system", "value": "Use new back-end sample's path instead of url\n" }, { "from": "human", "value": "class ApiClient {\n constructor(baseUrl) {\n this.baseUrl = baseUrl;\n }\n\n getSamples() {\n return fetch(`${this.baseUrl}/samples`)\n .then((response) => {\n if (...
javascript
chosen
[ { "from": "system", "value": "Use define as it seems to work correctly?\n" }, { "from": "human", "value": "require([\n 'angular',\n 'app',\n 'moment',\n\n 'app/controllers/default',\n 'app/controllers/loginSudo',\n 'app/controllers/manageTeamOwnership',\n 'app/controllers/projectStream',\...
javascript
chosen
[ { "from": "system", "value": "Refactor a variable and add a comment to be more clear.\n" }, { "from": "human", "value": "$(document).ready(function() {\n $(window).hashchange(function() {\n var currentHash = location.hash ? location.hash : '#home';\n\n $('.content-tab').not(curr...
javascript
chosen
[ { "from": "system", "value": "Update test to use version\n" }, { "from": "human", "value": "Npm.depends({\n\t'lodash': '3.5.0'\n});\n\nPackage.describe({\n\tsummary: \"A utility library delivering consistency, customization, performance, & extras.\",\n\tversion: \"3.5.0\",\n\tgit: \"https://gith...
javascript
chosen
[ { "from": "system", "value": "Fix log for grunt tasks\n" }, { "from": "human", "value": "(function() {\n\n 'use strict';\n\n var yeoman = require('yeoman-generator'),\n scaffold = {};\n\n module.exports = yeoman.generators.Base.extend({\n\n constructor: function() {\n ...
javascript
chosen
[ { "from": "system", "value": "Change button link to point to Donorbox page\n\n" }, { "from": "human", "value": "import React from 'react';\n// import PropTypes from 'prop-types';\nimport Section from 'shared/components/section/section';\nimport LinkButton from 'shared/components/linkButton/linkB...
javascript
chosen
[ { "from": "system", "value": "Use built in logging method\n" }, { "from": "human", "value": "const models = {\n page: require('../models/page'),\n user: require('../models/user')\n}\n\nconst remove = [\n '_id',\n 'id',\n 'password',\n '__v'\n]\n\nexports.one = function *(type, _id) {\n co...
javascript
chosen
[ { "from": "system", "value": "Add optional overrides to contour handleStyleDefaults\n" }, { "from": "human", "value": "/**\n* Copyright 2012-2017, Plotly, Inc.\n* All rights reserved.\n*\n* This source code is licensed under the MIT license found in the\n* LICENSE file in the root directory of t...
javascript
chosen
[ { "from": "system", "value": "Refactor tests to (hopefully) pass the build on 0.10\n" }, { "from": "human", "value": "\nimport React from 'react/addons';\nimport Animator from '../Animator.jsx';\n\nconst TestUtils = React.addons.TestUtils;\n\nconst animate = new Animator();\n\nconst SimpleCompon...
javascript
chosen
[ { "from": "system", "value": "Remove arrow functions to not confuse eslint, and fix lint issues\n" }, { "from": "human", "value": "\"use strict\";\n\nvar fs = require(\"fs\");\nvar utils = require(\"./utils\");\n\nmodule.exports = function zip(request) {\n return {\n download: function...
javascript
chosen
[ { "from": "system", "value": "Add \"watch\" pub/sub API as a builtin command\n" }, { "from": "human", "value": "var command = require('../command');\n\nmodule.exports = {\n// 'status': {},\n 'search': new command.SocketRequestResponse()//,\n// 'createtable': {},\n// 'removetable': {},\n// '...
javascript
chosen
[ { "from": "system", "value": ":recycle: Save anonymous function that remove added elements of HaTeMiLe in varible\n" }, { "from": "human", "value": "initHaTeMiLeForBrowser = function() {\n\ttry {\n\t\tvar configure = new hatemile.util.Configure({'prefix-generated-ids': 'id-cs-hatemile-firefox-' ...
javascript
chosen
[ { "from": "system", "value": "Fix view created without context.\n" }, { "from": "human", "value": "/**\n * @license\n * Copyright 2020 The FOAM Authors. All Rights Reserved.\n * http://www.apache.org/licenses/LICENSE-2.0\n */\n\nfoam.CLASS({\n package: 'foam.u2.view',\n name: 'ObjAltView',\n ...
javascript
chosen
[ { "from": "system", "value": "Allow user to pass in onload event for error handling\n" }, { "from": "human", "value": "(function ($) {\n\n var methods = {\n _download: function (options) {\n var triggerDelay = (options && options.delay) || 100;\n var cleaningDelay...
javascript
chosen
[ { "from": "system", "value": "Replace this with closed over in event closure\n" }, { "from": "human", "value": "myApp.service('breadCrumbService', function($location, $rootScope) {\n\n $rootScope.$on('$routeChangeSuccess', function (e, curr, prev) {\n this.update(curr.locals.breadCrum...
javascript
chosen
[ { "from": "system", "value": "Add notes to each function\n" }, { "from": "human", "value": "// Merge Sort\n\n/*RULES:\n Two function algorithm\n function mergeSort(arr){\n // take in a single, unsorted array as a parameter\n // split the array into two halves\n }\n\n function merge (ar...
javascript
chosen
[ { "from": "system", "value": "Add build-raw-files log; fixes 12603\n\nBS3 commits: 7100e3a37eedf31f6ba005bb045ee3074a6ee5ed\n" }, { "from": "human", "value": "/* global btoa: true */\n/*!\n * Bootstrap Grunt task for generating raw-files.min.js for the Customizer\n * http://getbootstrap.com\n * ...
javascript
chosen
[ { "from": "system", "value": "Add version constraint to collection-instances\n" }, { "from": "human", "value": "Package.describe({\n\tdocumentation: 'README.md',\n\tgit: 'https://github.com/hansoft/meteor-logger-mongo.git',\n\tname: 'hansoft:logger-mongo',\n\tsummary: 'Store console.<log/warn/er...
javascript
chosen
[ { "from": "system", "value": "Fix meteor account name & directory path.\n" }, { "from": "human", "value": "Package.describe({\n name: \"benjdl:sigma\",\n summary: \"Sigma is a library dedicated to graph drawing.\",\n version: \"1.0.3\",\n git: \"https://github.com/benjdl/meteor-sigma\"\n});\...
javascript
chosen
[ { "from": "system", "value": "Save hometown and current location into user profile\n" }, { "from": "human", "value": "// Accounts.loginServiceConfiguration.remove({\n// service: \"facebook\"\n// });\n// Accounts.loginServiceConfiguration.insert({\n// service: \"facebook\",\n// appId:...
javascript
chosen
[ { "from": "system", "value": "Change test to only have one 'done' call\n" }, { "from": "human", "value": "/**\n * Created by stephen on 03/03/14.\n */\ndescribe('feeds', function(){\n var session;\n before(function () {\n //Simulate a user login session\n session = new Sessio...
javascript
chosen
[ { "from": "system", "value": "Fix JSHint error in dashboard\n" }, { "from": "human", "value": "'use strict';\n\nvar angular = require('angular');\nvar directives = require('../scripts/modules').directives;\n\nangular.module(directives.name).directive('dashboardWidget', function () {\n return {\...
javascript
chosen
[ { "from": "system", "value": "Update deps to use new UI helpers\n" }, { "from": "human", "value": "Package.describe({\n \"summary\": \"Add feature flagging to Meteor\"\n});\n\nPackage.on_use(function (api) {\n api.use('coffeescript', ['server', 'client']);\n api.use(['deps','handlebars'...
javascript
chosen
[ { "from": "system", "value": "Add comment to example callback\n" }, { "from": "human", "value": "function newNexusHost(nexusServer, hostName) {\n if(!nexusServer) throw new Error('Missing nexusServer address');\n if(!hostName) throw new Error('Missing hostName');\n\n const pub = {};\n\n pub....
javascript
chosen
[ { "from": "system", "value": "Windows: Change 'platforms' to 'platform' when testing 'create'\n" }, { "from": "human", "value": "// Copyright © 2014 Intel Corporation. All rights reserved.\n// Use of this source code is governed by an Apache v2\n// license that can be found in the LICENSE-A...
javascript
chosen
[ { "from": "system", "value": "Change router view mode to history\n\n" }, { "from": "human", "value": "import Vue from 'vue'\nimport Router from 'vue-router'\nimport LandingPage from '@/components/LandingPage/LandingPage'\n\nVue.use(Router)\n\nexport default new Router({\n routes: [\n {\n ...
javascript
chosen
[ { "from": "human", "value": "Fix broken detail section due to missing URI label\nfilter.\n\n" }, { "from": "gpt", "value": "module.exports = function () {\n return function (uri) {\n var uriLabel = '';\n if (uri !== undefined && uri !== '') {\n var lastSlash = uri.lastIndexOf('/');\n...
javascript
chosen
[ { "from": "system", "value": "Add application parameter for unit system\n" }, { "from": "human", "value": "App.module(\"Main\", function(Main, App, Backbone, Marionette, $, _) {\n\n Main.init = function(options) {\n Main.controller = new Main.Controller();\n Main.router = new Main.Router(...
javascript
chosen
[ { "from": "system", "value": "Add acceptance test for closing alert\n" }, { "from": "human", "value": "import Ember from 'ember';\nimport { module, test } from 'qunit';\nimport startApp from 'component-integration-tests/tests/helpers/start-app';\n\nlet application;\n\nmodule('Acceptance | index'...
javascript
chosen
[ { "from": "system", "value": "fix: Attach event listeners to streams after creation\n" }, { "from": "human", "value": "import { SevenZipStream } from './stream.js'\n\n/**\n * Add command\n * @param archive {String} Path to the archive\n * @param source {String|Array} Source to add\n * @param opt...
javascript
chosen
[ { "from": "system", "value": "Stop closing the connection. Rely on the pool\n" }, { "from": "human", "value": "var mssql = require(\"mssql\");\n\nvar database = {\n query: function(connection, query, callback) {\n mssql.connect(connection, function(connectionError) {\n if(connectionErro...
javascript
chosen
[ { "from": "system", "value": "Hide ASCII container on error\n" }, { "from": "human", "value": "/*\n * ASCII Camera\n * http://idevelop.github.com/ascii-camera/\n *\n * Copyright 2013, Andrei Gheorghe (http://github.com/idevelop)\n * Released under the MIT license\n */\n\n(function() {\n\tvar asc...
javascript
chosen
[ { "from": "system", "value": "Enhance client testing… a little\n" }, { "from": "human", "value": "describe('Client-side', function() {\n var React = require('react/addons');\n var TestUtils = React.addons.TestUtils;\n var Router = require('react-router');\n var clientRoute = require('../exam...
javascript
chosen
[ { "from": "system", "value": "Update the auth header to include a gravatar\n" }, { "from": "human", "value": "\nenyo.kind({\n name: \"Bootplate.AuthenticatedHeaderView\",\n kind: \"enyo.FittableRows\",\n id: 'headerView',\n tag: 'header', // give it a specific html tag\n classes: \"onyx\",\...
javascript
chosen
[ { "from": "system", "value": "Remove use of jQuery in code-template-toggle\n" }, { "from": "human", "value": "import { schedule } from '@ember/runloop';\nimport Component from '@ember/component';\nimport $ from 'jquery';\n\nexport default Component.extend({\n classNames: [\"code-template-toggle...
javascript
chosen
[ { "from": "system", "value": "Remove unused require to Router\n" }, { "from": "human", "value": "const { Router } = require('express')\nconst cors = require('cors')\nconst bodyParser = require('body-parser')\nconst compression = require('compression')\n\nconst defaultMiddleware = (app) ...
javascript
chosen
[ { "from": "system", "value": "Handle passthrough from npm commands more reliably.\n" }, { "from": "human", "value": "var minimist = require('minimist')\n\nmodule.exports = require('rc')('prebuild', {\n target: process.version,\n arch: process.arch,\n platform: process.platform,\n compile: np...
javascript
chosen
[ { "from": "system", "value": "Add route for e-commerce site\n" }, { "from": "human", "value": "const express = require('express');\nconst hbs = require('hbs');\n\n// instantiate Express.js\nconst app = express();\n\n// Tell Handlebars where to look for partials\nhbs.registerPartials(__dirname + ...
javascript
chosen
[ { "from": "system", "value": "Load config via requires, web route added.\n" }, { "from": "human", "value": "/**\n * sivart-ci v0.1.0\n *\n * A simple interactive CI Dashboard built on MEAN stack.\n *\n * Author: Kushal Pandya <kushalspandya@gmail.com> (https://doublslash.com)\n * Date: 27 Novemb...
javascript
chosen
[ { "from": "system", "value": "Use ES2015 support in node 4.x\n" }, { "from": "human", "value": "var config = require('config');\nvar express = require('express');\nvar logger = require('morgan');\n\nvar app = new express();\n\n// ## Middleware\n\napp.use(logger('dev'));\napp.use(express.static(_...
javascript
chosen
[ { "from": "system", "value": "Add \"use strict\" + code cleanup\n" }, { "from": "human", "value": "var argv = require(\"optimist\")\n .boolean(['fetchtags'])\n .default('url', 'http://downloads.vagrantup.com')\n .default('file', 'checksums.json')\n .default('tag', 'v1.3.3')\n .default(...
javascript
chosen
[ { "from": "system", "value": "Fix to allow for the fact that we're using git submodules but npm\ndoesn't include the .git folder when downloading.\n" }, { "from": "human", "value": "#!/usr/bin/env node\nvar exec = require('child_process').exec;\nvar fs = require('fs');\n\nconsole.log(__dirname, ...
javascript
chosen
[ { "from": "system", "value": "Change interval from 5min to 10min\n" }, { "from": "human", "value": "(function() {\n setInterval(function () {\n var button_selectors = [\n '#session_continuity', /* klms.kaist.ac.kr */\n '.sessionExtension', /* ssogw6.kaist.ac.kr */\n ];\n for ...
javascript
chosen
[ { "from": "system", "value": "Add Groups to config page\n" }, { "from": "human", "value": "AdminConfig = {\n name: \"Juhani Wellbeing\",\n adminEmails: ['test@test.com'],\n skin: \"blue-light\",\n collections:\n {\n ActivityTypes: {\n icon: \"heart-o\",\n label: \"Activity Type...
javascript
chosen
[ { "from": "system", "value": "[server] Use multipleStatements mode in account deletion indexes script\n\nSummary: Without multipleStatements mode an error is returned `You have an error in your SQL syntax...`. Enabling multipleStatements fixes the issue.\n\nTest Plan: Run the script and check if indexes wer...
javascript
chosen
[ { "from": "system", "value": "Make the animation for timer sync with actual time.\n" }, { "from": "human", "value": "/**\n Build in browser timer.\n\n @param mountPoint CSS selector.\n @param options Timer options.\n @see Chart.js\n\n @author Joseph Fehrman\n @since 27/02/2017\n*/\nvar Tim...
javascript
chosen
[ { "from": "system", "value": "Use SGF loader if open file with unrecognized extension\n" }, { "from": "human", "value": "const {extname} = require('path')\n\nlet sgf = require('./sgf')\nlet ngf = require('./ngf')\nlet gib = require('./gib')\n\nlet modules = {sgf, ngf, gib}\n\nexports = module.ex...
javascript
chosen
[ { "from": "system", "value": "Use the `ViewStylePropTypes` since they work & inherit from `LayoutPropTypes`\n" }, { "from": "human", "value": "'use strict';\n\nvar VideoResizeMode = require('./VideoResizeMode');\nvar LayoutPropTypes = require('LayoutPropTypes');\nvar ReactPropTypes = require('R...
javascript
chosen
[ { "from": "system", "value": "Fix bug in ember-cli's new moduleForAcceptance.\n" }, { "from": "human", "value": "import { module } from 'qunit';\nimport startApp from '../helpers/start-app';\nimport destroyApp from '../helpers/destroy-app';\n\nexport default function(name, options = {}) {\n mod...
javascript
chosen
[ { "from": "system", "value": "JsMinify: Hide output textarea by default\n" }, { "from": "human", "value": "DDH.js_minify = DDH.js_minify || {};\n\n\"use strict\";\n\nDDH.js_minify.build = function(ops) {\n\n var shown = false;\n\n return {\n onShow: function() {\n // make...
javascript
chosen
[ { "from": "system", "value": "Copy over all cordova.cordova.* properties that plugins add to the cordova.* level\n\nThis is done by plugins like ionic-pluing-keyboard. They assume that cordova is available\non the window object - this does not have to be true\n" }, { "from": "human", "value": "/...
javascript
chosen
[ { "from": "system", "value": "Fix association model with user and email\n" }, { "from": "human", "value": "'use strict';\n\nvar fs = require('fs');\nvar path = require('path');\nvar Sequelize = require('sequelize');\nvar basename = path.basename(module.filename);\nvar env = pr...
javascript
chosen
[ { "from": "system", "value": "Use native path separators on Windows\n" }, { "from": "human", "value": "import path from 'path';\n\nimport CompositeGitStrategy from '../composite-git-strategy';\nimport {fsStat} from '../helpers';\n\n/**\n * Locate the nearest git working directory above a given s...
javascript
chosen
[ { "from": "system", "value": "Remove promisify module, wasnt promisifying nvim properly\n" }, { "from": "human", "value": "var attachWithCallback = require('./index');\nvar promisify = require('./promisify');\n\nmodule.exports = function attach(writer, reader) {\n return new Promise(function(re...
javascript
chosen
[ { "from": "system", "value": "Add waypoint for header class switch\n" }, { "from": "human", "value": "document.addEventListener('DOMContentLoaded', function() {\n console.log('DOM Content Loaded');\n});\n" }, { "from": "gpt", "value": "document.addEventListener('DOMContentLoaded', f...
javascript
chosen
[ { "from": "system", "value": "Update display of font size and line height\n" }, { "from": "human", "value": "function RGBToHex(RGB) {\n const RGBParts = RGB.match(/^rgb\\((\\d+),\\s*(\\d+),\\s*(\\d+)\\)$/);\n const HexArr = [];\n\n delete RGBParts[0];\n\n RGBParts.forEach((value) => {\n l...
javascript
chosen
[ { "from": "system", "value": "Reduce log spam from time not being synced yet\n" }, { "from": "human", "value": "import { extendClock, ProgressiveBackoff } from '../universal/time'\n\n\nconst TimeSync = global.TimeSync\n\nconst localClock = () => new Date()\n\nconst serverSyncClock = () => {\n c...
javascript
chosen
[ { "from": "system", "value": "Add redirect route from root to setup" }, { "from": "human", "value": "import React, { Component } from 'react'\nimport { Router, Route, hashHistory } from 'react-router'\nimport './App.css'\nimport Setup from './Setup'\nimport SetupWelcome from '...
javascript
chosen
[ { "from": "system", "value": "Disable logout prompt for nonregistered users\n" }, { "from": "human", "value": "$(document).ajaxError(function(event, jXHR) {\n if (jXHR.status === 403) {\n var message = gettext(\n 'You have been logged out of your edX account. ' +\n ...
javascript
chosen
[ { "from": "system", "value": "Use https for lorempixel to avoid mixed-content security warnings\n" }, { "from": "human", "value": "import Ember from 'ember';\nimport RSVP from 'rsvp';\nimport DS from 'ember-data';\n\nimport config from '../config/environment';\nimport buildQueryParamsMixin from ...
javascript
chosen
[ { "from": "system", "value": "text-effects[depth]: Remove blur if blur radius is 0.\n\nThis gets rid of visual artifacts that occur when a transform is\ncombined with a blur of radius 0.\n" }, { "from": "human", "value": "/*exported DepthElement*/\nvar DepthElement = (function() {\n 'use strict...
javascript
chosen
[ { "from": "system", "value": "Fix mis-named event-handler that was never getting executed.\n" }, { "from": "human", "value": "function ResponseEditWindow(responseID) {\n\tvar SurveyDetailsView = require('ui/common/surveys/SurveyDetailsView')\n\tvar ResponsesIndexView = require('ui/common/respons...
javascript
chosen