This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### Keybase proof | |
I hereby claim: | |
* I am kojilab on github. | |
* I am omoratin (https://keybase.io/omoratin) on keybase. | |
* I have a public key ASBdcT5P4lJ3o-QdBX4PAYoPUNOpANXaLdgAKXBql5Wi7Qo | |
To claim this, I am signing this object: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Array.prototype.flatten = function() { | |
return this.reduce(function(acc, v) { | |
if (!Array.isArray(v)) { | |
acc.push(v) | |
} else { | |
acc = acc.concat(v.flatten()) | |
} | |
return acc; | |
}, []) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$.fn.showKeywords = function(kwds) { | |
kws = kwds || []; | |
if (!$.isArray(kwds) || kwds.length === 0) return this; | |
var str = $.trim(kwds.join('|')); | |
if (str.length === 0) return this; | |
var regex = new RegExp('\\b('+str+')\\b', 'gim'); | |
this.each(function() { | |
var children = $(this).children(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
use Phalcon\DI\FactoryDefault, | |
Phalcon\Mvc\Micro, | |
Phalcon\Config\Adapter\Ini as IniConfig, | |
Phalcon\Mvc\Micro\Collection as MicroCollection; | |
$di = new FactoryDefault(); | |
$di->set('url', function(){ | |
$url = new Phalcon\Mvc\Url(); | |
$url->setBaseUri('/'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Tooltipster 2.1 | 2/12/13 | |
A rockin' custom tooltip jQuery plugin | |
Developed by: Caleb Jacob - calebjacob.com | |
Copyright (C) 2013 Caleb Jacob | |
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module.exports = function (req,res,ok) { | |
var requiresUserId = false; | |
// not all records may need the user ID so let's see what entity we're dealing with in the call | |
switch(req.params.entity) { | |
case 'project': | |
case 'task': | |
requiresUserId = true; | |
break; | |
} |