Cut out unnecessary javascript