From 175a760fc96395aaf26ce0c81eb90b62ea0c8ede Mon Sep 17 00:00:00 2001 From: Mihai Todor Date: Fri, 13 Dec 2024 14:19:10 +0000 Subject: [PATCH] Fix error handling in OCF example Signed-off-by: Mihai Todor --- ocf/example_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ocf/example_test.go b/ocf/example_test.go index b8b014a7..ee09e5c4 100644 --- a/ocf/example_test.go +++ b/ocf/example_test.go @@ -34,7 +34,7 @@ func ExampleNewDecoder() { // Do something with the data } - if dec.Error() != nil { + if err := dec.Error(); err != nil { log.Fatal(err) } }