Skip to content

Commit

Permalink
misc: standardize variable naming (#46)
Browse files Browse the repository at this point in the history
Resolves issue #40.
  • Loading branch information
gsilvapt authored Dec 28, 2022
1 parent c7ec851 commit 30e55cf
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cmd/new.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ If a template is specified and you use the --title flag, it will try to insert t
func newNoteFunc(cmd *cobra.Command, args []string) {
ztldir := viper.GetString("ztldir")
editor := viper.GetString("editor")
tmpl_path := viper.GetString("notetemplate")
tmplPath := viper.GetString("notetemplate")
title, _ := cmd.Flags().GetString("title")
toOpen, _ := cmd.Flags().GetBool("open")

Expand All @@ -46,8 +46,8 @@ func newNoteFunc(cmd *cobra.Command, args []string) {
f := createFile(ztldir, formattedTs, title)
defer f.Close()

if tmpl_path != "" {
writeTmplToNote(f, title, tmpl_path)
if tmplPath != "" {
writeTmplToNote(f, title, tmplPath)
}

if toOpen {
Expand Down

0 comments on commit 30e55cf

Please sign in to comment.