Skip to content

Commit 8fa772f

Browse files
author
Andre Lanrezac
committed
Remove useless condition in getnbcustom data functions
1 parent a62bfae commit 8fa772f

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

plugins/UnityMol/UMolMDDriver.cpp

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -206,16 +206,12 @@ int MDDriver_getNbParticles(MDDriverAdapter *mddinstance) {
206206
}
207207

208208
int MDDriver_getNbCustomFloat(MDDriverAdapter *mddinstance) {
209-
if (mddinstance->N_floats <= 0) {
210-
IIMD_get_nb_custom_float(&(mddinstance->N_floats));
211-
}
209+
IIMD_get_nb_custom_float(&(mddinstance->N_floats));
212210
return mddinstance->N_floats;
213211
}
214212

215213
int MDDriver_getNbCustomInt(MDDriverAdapter *mddinstance) {
216-
if (mddinstance->N_ints <= 0) {
217-
IIMD_get_nb_custom_int(&(mddinstance->N_ints));
218-
}
214+
IIMD_get_nb_custom_int(&(mddinstance->N_ints));
219215
return mddinstance->N_ints;
220216
}
221217

0 commit comments

Comments
 (0)