 
 		generateAfter: (opts) ->
 			return @ if !@lrServer
+			docpad = @docpad
 			files = []
 			collection = docpad.getDatabase().findAll({
 				mtime: {


		serverAfter: (opts) ->
			config = @config
			port = config.port
			docpad.log('info','Starting TinyLiveReload')


			@lrServer.changed({body:{files:files}});
			docpad.log('info','changed files are sent')

			@
