File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ var okPage = []byte(`
2828</html>
2929` )
3030
31- var failPage = [] byte ( `
31+ const failPage = `
3232<!DOCTYPE html>
3333<html>
3434<head>
@@ -40,7 +40,7 @@ var failPage = []byte(`
4040 <p>Error details: error %s error_description: %s</p>
4141</body>
4242</html>
43- ` )
43+ `
4444
4545// Result is the result from the redirect.
4646type Result struct {
@@ -153,7 +153,7 @@ func (s *Server) handler(w http.ResponseWriter, r *http.Request) {
153153 desc := html .EscapeString (q .Get ("error_description" ))
154154 // Note: It is a little weird we handle some errors by not going to the failPage. If they all should,
155155 // change this to s.error() and make s.error() write the failPage instead of an error code.
156- _ , _ = w .Write ([]byte (fmt .Sprintf (string ( failPage ) , headerErr , desc )))
156+ _ , _ = w .Write ([]byte (fmt .Sprintf (failPage , headerErr , desc )))
157157 s .putResult (Result {Err : fmt .Errorf (desc )})
158158 return
159159 }
You can’t perform that action at this time.
0 commit comments