mirror of
				https://github.com/aclindsa/moneygo.git
				synced 2025-10-29 17:13:26 -04:00 
			
		
		
		
	Remove unused WriteError function
This commit is contained in:
		| @@ -41,17 +41,8 @@ var error_codes = map[int]string{ | |||||||
| func NewError(error_code int) *Error { | func NewError(error_code int) *Error { | ||||||
| 	msg, ok := error_codes[error_code] | 	msg, ok := error_codes[error_code] | ||||||
| 	if !ok { | 	if !ok { | ||||||
| 		log.Printf("Error: WriteError received error code of %d", error_code) | 		log.Printf("Error: NewError received unknown error code of %d", error_code) | ||||||
| 		msg = error_codes[999] | 		msg = error_codes[999] | ||||||
| 	} | 	} | ||||||
| 	return &Error{error_code, msg} | 	return &Error{error_code, msg} | ||||||
| } | } | ||||||
|  |  | ||||||
| func WriteError(w http.ResponseWriter, error_code int) { |  | ||||||
| 	e := NewError(error_code) |  | ||||||
|  |  | ||||||
| 	err := e.Write(w) |  | ||||||
| 	if err != nil { |  | ||||||
| 		log.Fatal(err) |  | ||||||
| 	} |  | ||||||
| } |  | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user