Skip to content

Instantly share code, notes, and snippets.

def self.fetch_cache(user)
#Make sure the user has companies to cache (based on companies they're a team member of)
if user.profile.team.companies.count > 0
return Rails.cache.fetch(user.profile.team.companies) {
user.profile.team.companies
}
end
end
# .bashrc
echo processing ~/.bashrc
#required to get X11 working right (for ssh -X and gtk)
export DISPLAY=:0
# git will show dirty branches
GIT_PS1_SHOWDIRTYSTATE=true
# colors that "ls" uses.
def nested_hash_value(obj,key)
if obj.respond_to?(:key?) && obj.key?(key)
obj[key]
elsif obj.respond_to?(:each)
r = nil
obj.find{ |*a| r=nested_hash_value(a.last,key) }
r
end
end
change this:
<blockquote class="tr_bq">
<div style="text-align: left;">
<span style="font-size: large;">Crockpot Caramel Apple Butter</span></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
<div style="text-align: left;">
1/2 cup white sugar</div>
(function assignSlideIds(){
for(var i in $scope.avContent){
$scope.avContent[i].id = utils.uniqueId('article_');
}
}());
utils.each($scope.avContent, function(av){
av.id = utils.uniqueId('article_');
});
LOG: {0: <div></div>, length: 1}
LOG: {0: <div></div>, length: 1}
Chrome 33.0.1750 (Mac OS X 10.8.5) Swoop2Placements debug component placements component mananger should call render with expected arguments FAILED
Expected { 0 : HTMLNode, length : 1 } to equal { 0 : HTMLNode, length : 1 }.
http://www.health.com/health/m/article/0,,20456225,00.html?swtags=demo
http://wallstcheatsheet.com/personal-finance/a-guide-to-prepaid-debit-cards.html/?swtags=demo
Uncaught TypeError: Cannot read property 'module' of undefined angular-route.js:24
Uncaught Error: [$injector:modulerr] Failed to instantiate module burnMob due to:
Error: [$injector:modulerr] Failed to instantiate module ngRoute due to:
Error: [$injector:nomod] Module 'ngRoute' is not available! You either misspelled the module ...<omitted>...1)
<img id="UNIQUE ID, USE ONCE PER PAGE" src="IMAGE BACKGROUND URL" usemap="#MAPNAME" border="0" width="560" height="305" orgwidth="560" orgheight="305" alt="">
<map name="mapname" id="mapname">
<area alt="" title="" href="BUTTONLINK1" target="_blank" shape="rect" coords="416,230,526,261" style="outline:none;">
<area alt="" title="" href="BUTTONLINK2" shape="rect" coords="32,229,146,266" style="outline:none;" target="_blank">
</map>