diff options
author | Asbjørn Sloth Tønnesen <ast@2e8.dk> | 2020-02-17 18:47:11 +0000 |
---|---|---|
committer | Asbjørn Sloth Tønnesen <ast@2e8.dk> | 2020-02-17 20:29:00 +0000 |
commit | 915121994184739af16b03b5b50212adda503a19 (patch) | |
tree | 860df50a55f3a9d17f65606568fe0d273f0e2f7a /lua | |
parent | 1df3b14bdfd26470c007b8443979cd20df0ea649 (diff) | |
download | lua-inet-915121994184739af16b03b5b50212adda503a19.tar.gz lua-inet-915121994184739af16b03b5b50212adda503a19.tar.xz lua-inet-915121994184739af16b03b5b50212adda503a19.zip |
add :full_family()
Signed-off-by: Asbjørn Sloth Tønnesen <ast@2e8.dk>
Diffstat (limited to 'lua')
-rw-r--r-- | lua/inet/core.lua | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lua/inet/core.lua b/lua/inet/core.lua index 398bc66..2b36543 100644 --- a/lua/inet/core.lua +++ b/lua/inet/core.lua @@ -75,6 +75,10 @@ function inet:family() return ret end +function inet:full_family() + return format('ipv%d', self:family()) +end + local ipv4_parser local ipv6_parser do |