Skip to content

Instantly share code, notes, and snippets.

View gangleton's full-sized avatar

Serena Wales gangleton

  • GovDelivery
  • San Francisco, CA/ New York, NY
View GitHub Profile
@gangleton
gangleton / gist:6084749
Created July 25, 2013 23:31
RailsAdmin trace
ActionView::Template::Error (undefined method `each' for #<Class:0x007fc844e6d430>):
60: - @filterable_fields.each do |field|
61: - field_options = case field.type
62: - when :enum
63: - options_for_select(field.with(:object => @abstract_model.model.new).enum)
64: - else
65: - ''
66: %li
activerecord (3.2.12) lib/active_record/dynamic_matchers.rb:55:in `method_missing'
actionpack (3.2.12) lib/action_view/helpers/form_options_helper.rb:329:in `each'
@gangleton
gangleton / GrabBlockee.js
Created September 10, 2012 18:36 — forked from mapmeld/GrabBlockee.js
GrabBlockee.js
// grab background: StreetView or uploaded
// 600 x 435 pixels
var bg = $('canvas')[1].parentNode.style.backgroundImage.substring(4);
bg = bg.substring(0, bg.length - 1);
var bgimage = new Image();
bgimage.onload = function(){
// grab image from foreground canvas
// 600 x 435 pixels to avoid menus
var uppercanv = $('canvas')[1].getContext('2d').getImageData(0, 0, 600, 435);
set nocompatible
set number
set ruler
syntax on
" Set encoding
set encoding=utf-8
" Whitespace stuff