RFR: webrev: add logging [v2]

Erik Helin ehelin at openjdk.java.net
Thu Jun 18 13:41:44 UTC 2020


On Thu, 18 Jun 2020 12:32:30 GMT, Jorn Vernee <jvernee at openjdk.org> wrote:

>> Erik Helin has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Use `Collectors.joining`
>>   
>>   Co-authored-by: Jorn Vernee <JornVernee at users.noreply.github.com>
>
> webrev/src/main/java/org/openjdk/skara/webrev/ModifiedFileView.java line 56:
> 
>> 55:                                                    patch.source().hash() + " with target path" +
>> 56:                                                    patch.target().path().get())
>> 57:             );
> 
> Is this `get()` safe though? Maybe you want to extract the target path into a variable as well, since the
> `patch.target().path().get()` is used a few times below as well? (It would reduce the number of `get()` calls`, so less
> scrutiny needed).

Yeah, `path.target().path().get()` _should_ be safe. If the patch does not have `source` path nor have a `target` path,
then something is seriously wrong ��

-------------

PR: https://git.openjdk.java.net/skara/pull/674


More information about the skara-dev mailing list