extract method, see #15