Skip to content

Commit

Permalink
make streamName optional for KinesisInfo
Browse files Browse the repository at this point in the history
  • Loading branch information
michaeloffner committed Aug 8, 2024
1 parent d3a9874 commit e32e26c
Showing 1 changed file with 7 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -120,10 +120,13 @@ public Object invoke(PageContext pc, Object[] args) throws PageException {
if (args.length > 6) throw engine.getExceptionUtil().createFunctionException(pc, "KinesisInfo", 0, 6, args.length);

// streamName
String streamName = cast.toString(args[0]);
if (Util.isEmpty(streamName, true))
throw engine.getExceptionUtil().createFunctionException(pc, "KinesisGet", 1, "streamName", "invalid streamName [" + streamName + "],value cannot be empty", null);
else streamName = streamName.trim();
String streamName = null;
if (args.length > 0) {
streamName = cast.toString(args[0]);
if (Util.isEmpty(streamName, true))
throw engine.getExceptionUtil().createFunctionException(pc, "KinesisGet", 1, "streamName", "invalid streamName [" + streamName + "],value cannot be empty", null);
else streamName = streamName.trim();
}

// accessKeyId
String accessKeyId = null;
Expand Down

0 comments on commit e32e26c

Please sign in to comment.