The proverbial "bad pint" could be a thing of the past thanks to Scottish scientists who have secured a £30,000 grant as part of a major EU research programme for the brewing industry.
The project will bring together scientists from all over Europe as well as brewers from Britain and the continent.
Researchers from the University of Aberdeen will collect samples of microbes discovered by the brewers in beer which has been spoiled.
That information will then be used to develop a sophisticated microbiological test kit which brewers will be able to use to root out what is known as "spoilage organisms" before the beer goes on sale.
Scientists and researchers from Finland, Germany and Norway are joining the team from Aberdeen University's off-shoot company the National Collection of Industrial, Food and Marine Bacteria.
Terry Dando, the production and patent manager on the team, said it was important that breweries had an easy-to-use system that could detect low numbers of bacteria. Brewers could then use the system to make sure the taste and smell of the beer was not spoiled at a later stage.