[BUGFIX] Fix when writing custom amount such as "1000"