Skip to content

Instantly share code, notes, and snippets.

Started GET "/admin/employees/7" for 127.0.0.1 at 2012-02-22 17:39:13 +0100
Processing by Admin::EmployeesController#show as HTML
Parameters: {"id"=>"7"}
AdminUser Load (0.9ms) SELECT "admin_users".* FROM "admin_users" WHERE "admin_users"."id" = 2 LIMIT 1
Employee Load (0.9ms) SELECT "employees".* FROM "employees" WHERE "employees"."id" = $1 LIMIT 1 [["id", "7"]]
(1.3ms) SELECT COUNT(*) FROM "active_admin_comments" WHERE "active_admin_comments"."resource_type" = 'Employee' AND "active_admin_comments"."resource_id" = 7 AND "active_admin_comments"."namespace" = 'admin'
PGError: ERROR: operator does not exist: character varying = integer
LINE 1: ...ployee' AND "active_admin_comments"."resource_id" = 7 AND "a...
^
HINT: No operator matches the given name and argument type(s). You might need to add explicit type casts.
@nbartlomiej
nbartlomiej / lisense_api_draft_callbacks.js
Created September 27, 2011 16:59
Lisense API draft, callbacks
var wordsPerSentenceNotifier = new Notifier(wordCounter, sentenceCounter);
wordsPerSentenceNotifier.evaluate = function(wordCount, sentenceCount){
if(wordCount/sentenceCount>50){
var n = new Notification("I am so not going to read it.");
}
}
@nbartlomiej
nbartlomiej / lisense_api_draft.js
Created September 25, 2011 19:29
Lisense API draft
var wordScanner = new Scanner(WORD_REGEXP);
var wordCounter = new Counter(wordScanner);
var wordNotifier = new Notifier(wordCounter);
wordNotifier.evaluate = function(wordCount){
if(wordCount>1000){
var n = new Notification("I am so not going to read it.");
}
}