Skip to content

Commit

Permalink
Change 'lengths(x)' to 'sapply(x, length)' to work with R ver 3.1
Browse files Browse the repository at this point in the history
Signed-off-by: Stefan Widgren <stefan.widgren@gmail.com>
  • Loading branch information
stewid committed Dec 20, 2017
1 parent b203fb0 commit 1e4c96c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions R/status.r
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
## git2r, R bindings to the libgit2 library.
## Copyright (C) 2013-2016 The git2r contributors
## Copyright (C) 2013-2017 The git2r contributors
##
## This program is free software; you can redistribute it and/or modify
## it under the terms of the GNU General Public License, version 2,
Expand Down Expand Up @@ -134,7 +134,7 @@ print.git_status <- function(x, ...)
invisible(NULL)
}

if (max(lengths(x)) == 0L)
if (max(sapply(x, length)) == 0L)
cat("working directory clean\n")

if (length(x$ignored)) {
Expand Down

0 comments on commit 1e4c96c

Please sign in to comment.