mirror of
https://github.com/atom/atom.git
synced 2026-02-10 14:45:11 -05:00
Always relativize to working directory
This commit is contained in:
@@ -443,11 +443,8 @@ export default class GitRepositoryAsync {
|
|||||||
// value can be passed to {::isStatusModified} or {::isStatusNew} to get more
|
// value can be passed to {::isStatusModified} or {::isStatusNew} to get more
|
||||||
// information.
|
// information.
|
||||||
getDirectoryStatus (directoryPath) {
|
getDirectoryStatus (directoryPath) {
|
||||||
return this.getRepo()
|
return this.relativizeToWorkingDirectory(directoryPath)
|
||||||
.then(repo => {
|
.then(relativePath => this._getStatus([relativePath]))
|
||||||
const relativePath = this.relativize(directoryPath, repo.workdir())
|
|
||||||
return this._getStatus([relativePath])
|
|
||||||
})
|
|
||||||
.then(statuses => {
|
.then(statuses => {
|
||||||
return Promise.all(statuses.map(s => s.statusBit())).then(bits => {
|
return Promise.all(statuses.map(s => s.statusBit())).then(bits => {
|
||||||
return bits
|
return bits
|
||||||
|
|||||||
Reference in New Issue
Block a user