For now, ignore modified from import since we don't use it

This commit is contained in:
Radhi Fadlillah 2019-08-12 21:41:44 +07:00
parent e55070ca77
commit bd9d4b1d0c

View file

@ -4,9 +4,7 @@ import (
"fmt"
nurl "net/url"
"os"
"strconv"
"strings"
"time"
"github.com/PuerkitoBio/goquery"
"github.com/go-shiori/shiori/internal/model"
@ -74,9 +72,6 @@ func importHandler(cmd *cobra.Command, args []string) {
title := a.Text()
url, _ := a.Attr("href")
strTags, _ := a.Attr("tags")
strModified, _ := a.Attr("last_modified")
intModified, _ := strconv.ParseInt(strModified, 10, 64)
modified := time.Unix(intModified, 0)
// Clean up URL by removing its fragment and UTM parameters
tmp, err := nurl.Parse(url)
@ -126,7 +121,6 @@ func importHandler(cmd *cobra.Command, args []string) {
ID: bookID,
URL: url,
Title: normalizeSpace(title),
Modified: modified.Format("2006-01-02 15:04:05"),
Tags: tags,
}