mirror of
https://github.com/nishiki/manage-password.git
synced 2024-11-27 07:33:05 +00:00
fix sync when add new item
This commit is contained in:
parent
59f9a5d40f
commit
24949b2bde
1 changed files with 4 additions and 2 deletions
|
@ -104,14 +104,16 @@ module MPW
|
|||
# Add item
|
||||
@remote.list.each do |r|
|
||||
if r.last_edit > @config.last_update
|
||||
item = Item.new(name: r.name,
|
||||
item = Item.new(id: r.id,
|
||||
name: r.name,
|
||||
group: r.group,
|
||||
host: r.host,
|
||||
protocol: r.protocol,
|
||||
user: r.user,
|
||||
password: r.password,
|
||||
port: r.port,
|
||||
comment: r.comment
|
||||
comment: r.comment,
|
||||
created: r.created
|
||||
)
|
||||
raise @local.error_msg if not @local.add(item)
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue