Documentation
¶
Index ¶
- func GetOAuthClient(r *http.Request) (*http.Client, error)
- func GetOAuthToken(r *http.Request) (*oauth2.Token, error)
- func NewPaste(r *http.Request, score float64) (string, error)
- func SaveOAuthToken(w http.ResponseWriter, r *http.Request, token *oauth2.Token) error
- type GDriveAPIError
- type Paste
- type ValidationError
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SaveOAuthToken ¶
Types ¶
type GDriveAPIError ¶
type GDriveAPIError struct { Code int // The response code we received Response string // The response text we received }
func (*GDriveAPIError) Error ¶
func (e *GDriveAPIError) Error() string
type Paste ¶
type Paste struct { PasteID string `db:"paste_id"` UserID string `db:"user_id"` Title string `db:"title"` Content []byte `db:"content"` Tags []string `db:"tags"` Format string `db:"format"` Date time.Time `db:"date"` Gzip bool `db:"gzip"` Zlib bool `db:"zlib"` GDriveID string `db:"gdriveid"` GDriveDL string `db:"gdrivedl"` // contains filtered or unexported fields }
func (*Paste) LinkFromDrive ¶
type ValidationError ¶
func (*ValidationError) Error ¶
func (e *ValidationError) Error() string
Click to show internal directories.
Click to hide internal directories.