pulled fetching token value to its own method