chore: comments, lint

This commit is contained in:
blob42 2023-10-10 21:57:05 +02:00
parent 953aef2854
commit a3e1aae827
4 changed files with 4 additions and 4 deletions

View File

@ -55,6 +55,7 @@ var globalFirefoxFlags = []cli.Flag{
// Firefox global flags must start with --firefox-<flag name here>
// NOTE: is called in *cli.App.Before callback
//TODO: refactor module flags/options mangement to generate flags from config options
func globalCommandFlagsManager(c *cli.Context) error {
log.Debugf("<%s> registering global flag manager", BrowserName)
for _, f := range c.App.Flags {

View File

@ -113,7 +113,7 @@ func NewFirefoxConfig() *FirefoxConfig {
Stats: &parsing.Stats{},
UseFileWatcher: true,
// NOTE: see parsing.Hook to add custom parsing logic for each
// parsed node
// parsed bookmark node
UseHooks: []string{"notify-send"},
},
@ -151,8 +151,6 @@ func init() {
FFConfig = NewFirefoxConfig()
config.RegisterConfigurator(BrowserName, config.AsConfigurator(FFConfig))
// log.Debugf("%p", FFConfig)
// An example of running custom code when config is ready
// config.RegisterConfReadyHooks(func(c *cli.Context) error{
// // log.Debugf("%#v", config.GetAll().Dump())

View File

@ -42,6 +42,7 @@ func cleanup(f func() error) {
// Inserts or updates a bookmarks to the passed DB
// In case of a conflict for a UNIQUE URL constraint,
// update the existing bookmark
//TODO!: use context
func (db *DB) UpsertBookmark(bk *Bookmark) {
var sqlite3Err sqlite3.Error
@ -89,7 +90,6 @@ func (db *DB) UpsertBookmark(bk *Bookmark) {
tags := NewTags(bk.Tags, TagSep).PreSanitize()
tagListText := tags.String(true)
// log.Debugf("inserting tags %#v", tagListText)
// First try to insert the bookmark (assume it's new)
// log.Debugf("INSERT INTO bookmarks(URL, metadata, tags, desc, flags) VALUES (%s, %s, %s, %s, %d)",

View File

@ -34,6 +34,7 @@ func Init() {
initCache()
StartSyncScheduler()
// Check and initialize local db as last step
// browser bookmarks should already be in cache