Skip to content

Commit bfb435a

Browse files
authored
Merge pull request #11657 from u-blox/ubx_apn_setting
Cellular: Fix apn check
2 parents f6c28e5 + c8ade90 commit bfb435a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

features/cellular/framework/targets/UBLOX/AT/UBLOX_AT.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,14 +126,14 @@ nsapi_error_t UBLOX_AT::config_authentication_parameters()
126126
nsapi_error_t err;
127127
char imsi[MAX_IMSI_LENGTH + 1];
128128

129-
if (apn == NULL) {
129+
if (ubx_context->get_apn() == NULL) {
130130
err = get_imsi(imsi);
131131
if (err == NSAPI_ERROR_OK) {
132132
config = (char *)apnconfig(imsi);
133133
}
134+
ubx_context->get_next_credentials(&config);
134135
}
135136

136-
ubx_context->get_next_credentials(&config);
137137
apn = ubx_context->get_apn();
138138
pwd = ubx_context->get_pwd();
139139
uname = ubx_context->get_uname();

0 commit comments

Comments
 (0)