mirror of
https://github.com/scm-manager/scm-manager.git
synced 2026-02-26 16:30:50 +01:00
Adds 'head' as revision for Subversion repositories
To still support the editor plugin, a new field in the browse command results is needed to indicate, whether such a result or rather the requested revision can be modified by a new commit. This is the case, when - for Subversion repositories either the new 'head' or the latest revision has been requested, or - for Git and HG when a branch (or the default by specifying no concrete revision) has been used.
This commit is contained in:
@@ -40,7 +40,7 @@ public abstract class BrowserResultToFileObjectDtoMapper extends BaseFileObjectD
|
||||
|
||||
FileObjectDto map(BrowserResult browserResult, NamespaceAndName namespaceAndName, int offset) {
|
||||
FileObjectDto fileObjectDto = fileObjectToDto(browserResult.getFile(), namespaceAndName, browserResult, offset);
|
||||
fileObjectDto.setRevision(browserResult.getRevision());
|
||||
fileObjectDto.setRevision(browserResult.getRequestedRevision());
|
||||
|
||||
return fileObjectDto;
|
||||
}
|
||||
@@ -59,7 +59,7 @@ public abstract class BrowserResultToFileObjectDtoMapper extends BaseFileObjectD
|
||||
applyEnrichers(appender, browserResult, namespaceAndName);
|
||||
}
|
||||
// we call enrichers, which are responsible for all file object top level browse result and its children
|
||||
applyEnrichers(appender, fileObject, namespaceAndName, browserResult, browserResult.getRevision());
|
||||
applyEnrichers(appender, fileObject, namespaceAndName, browserResult, browserResult.getRequestedRevision());
|
||||
}
|
||||
|
||||
Optional<Instant> mapOptionalInstant(OptionalLong optionalLong) {
|
||||
|
||||
Reference in New Issue
Block a user