aboutsummaryrefslogtreecommitdiff
path: root/internal/feed/feed.go
diff options
context:
space:
mode:
Diffstat (limited to 'internal/feed/feed.go')
-rw-r--r--internal/feed/feed.go28
1 files changed, 1 insertions, 27 deletions
diff --git a/internal/feed/feed.go b/internal/feed/feed.go
index a43b7e9..c013877 100644
--- a/internal/feed/feed.go
+++ b/internal/feed/feed.go
@@ -9,9 +9,7 @@ import (
)
const (
- DataVersion40 = iota // Version 4.0
-
- OrNodeOp // OR operator
+ OrNodeOp = iota // OR operator
AndNodeOp // And operator
AdjacentNetwork // Adjacent Network attack vector.
@@ -42,30 +40,6 @@ const (
// TODO: parse cpe
-// Data version for NVD feeds and feed items.
-type DataVersion int
-
-// Unmarshal DataVersion from JSON.
-func (me *DataVersion) UnmarshalJSON(b []byte) error {
- // decode string, check for error
- var s string
- if err := json.Unmarshal(b, &s); err != nil {
- return err
- }
-
- // check value
- switch s {
- case "4.0":
- *me = DataVersion40
- default:
- // return error
- return fmt.Errorf("unknown data version: %s", s)
- }
-
- // return success
- return nil
-}
-
// partial timestamp
type PartialTime time.Time