From b2ece1641265125e8b0a16b44213df68ddf52596 Mon Sep 17 00:00:00 2001 From: Robbie Trencheny Date: Fri, 7 Apr 2017 14:16:23 -0700 Subject: [PATCH] Add IsClosed method to Session --- session.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/session.go b/session.go index 00aab67..22e6a93 100644 --- a/session.go +++ b/session.go @@ -193,3 +193,8 @@ func (s *Session) MustGet(key string) interface{} { panic("Key \"" + key + "\" does not exist") } + +// IsClosed returns the status of the connection. +func (s *Session) IsClosed() bool { + return s.closed() +}