Last will return the last added write
()
| 22 | |
| 23 | // Last will return the last added write |
| 24 | func (w *ConditionalWrite) Last() string { |
| 25 | if len(w.Queued) == 0 { |
| 26 | return "" |
| 27 | } |
| 28 | return w.Queued[len(w.Queued)-1] |
| 29 | } |
| 30 | |
| 31 | // Flush will return all queued writes, and return |
| 32 | // "" (empty string) in nothing has been queued |
nothing calls this directly
no outgoing calls
no test coverage detected