I hereby claim:
- I am mrvdot on github.
- I am mrvdot (https://keybase.io/mrvdot) on keybase.
- I have a public key ASCKW7tcpW8QQGfZe-OgBxrVr0T9Z3s9w0thHospu3VamAo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
// Generated on 2014-10-16 using generator-angular 0.9.7 | |
'use strict'; | |
// # Globbing | |
// for performance reasons we're only matching one level down: | |
// 'test/spec/{,*/}*.js' | |
// use this if you want to recursively match all subfolders: | |
// 'test/spec/**/*.js' | |
module.exports = function (grunt) { |
func Save(c appengine.Context, obj interface{}) (key *datastore.Key, err error) { | |
kind, val := reflect.TypeOf(obj), reflect.ValueOf(obj) | |
str := val | |
if val.Kind().String() == "ptr" { | |
kind, str = kind.Elem(), val.Elem() | |
} | |
if str.Kind().String() != "struct" { | |
return nil, errors.New("Must pass a valid object to struct") | |
} | |
dsKind := kind.String() |
import ( | |
"io" | |
"net/http" | |
) | |
//With HandlerFunc | |
func main () { | |
http.Handle("/", JsonpHandler(http.HandlerFunc(func (w http.ResponseWriter, r *http.Request) { | |
w.Write("Hello World") | |
}))) |