File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed
async/async-commons-starter/src/main/java/org/reactivecommons/async/impl/config Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change 99import java .time .temporal .ChronoUnit ;
1010import java .util .ArrayList ;
1111import java .util .List ;
12+ import java .util .Optional ;
1213
1314@ ConfigurationProperties (prefix = "spring.rabbitmq" )
1415public class RabbitProperties {
@@ -923,12 +924,15 @@ private String trimPrefix(String input) {
923924 private String parseUsernameAndPassword (String input ) {
924925 if (input .contains ("@" )) {
925926 String [] split = StringUtils .split (input , "@" );
927+ if (split == null ) return input ;
926928 String creds = split [0 ];
927929 input = split [1 ];
928930 split = StringUtils .split (creds , ":" );
929- this .username = split [0 ];
930- if (split .length > 0 ) {
931- this .password = split [1 ];
931+ if (split != null ) {
932+ this .username = split [0 ];
933+ if (split .length > 1 ) {
934+ this .password = split [1 ];
935+ }
932936 }
933937 }
934938 return input ;
You can’t perform that action at this time.
0 commit comments