Skip to content
This repository was archived by the owner on Dec 15, 2022. It is now read-only.
This repository was archived by the owner on Dec 15, 2022. It is now read-only.

Directory::onDidChange / File::onDidChange fire twice on file save if file not empty #74

Description

@izuzak

From @paulpflug on June 22, 2015 9:58

console.log "watching"
fired = false
entry.onDidChange ->
  console.log "fire"
  unless fired
    fired = true
    console.log "real fire"
    setTimeout (->fired = false), 1000

Output:

watching
## saving empty file
fire
real fire
## saving file with content
fire
real fire
fire

Copied from original issue: atom/atom#7363

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions